1MSR_INIT(3)                Library Functions Manual                MSR_INIT(3)
2
3
4

NAME

6       msr_init - Initializing and freeing MSRecord and related structures
7
8

SYNOPSIS

10       #include <libmseed.h>
11
12       MSRecord *msr_init ( MSRecord *msr );
13
14       void      msr_free ( MSRecord **ppmsr );
15
16       void      msr_free_blktchain ( MSRecord *msr );
17
18

DESCRIPTION

20       msr_init will initialize a MSRecord structure.  If the msr parameter is
21       NULL a new structure will be allocated.  If the msr  parameter  is  not
22       NULL  the blockette chain (MSRecord.blkts) will be freed but any memory
23       allocated for MSRecord.fsdh and MSRecord.datasamples will be  preserved
24       as it will cleanly be re-used by routines such as msr_unpack(3).
25
26       msr_free  will  free  all  memory  associated with a MSRecord structure
27       including the blockette chain and set the structure pointer (*ppmsr) to
28       0.
29
30       msr_free_blktchain  will  free all memory associated with the blockette
31       chain of an MSRecord structure.  The shortcut blockette  pointers  will
32       also be reset.
33
34

RETURN VALUES

36       msr_init  returns  a  pointer  to the MSRecord structure initialized on
37       success or NULL on error.
38
39

SEE ALSO

41       ms_intro(3), msr_pack(3) and msr_unpack(3).
42
43

AUTHOR

45       Chad Trabant
46       IRIS Data Management Center
47
48
49
50Libmseed API                      2006/02/27                       MSR_INIT(3)
Impressum