cfp_getln(3) manual page
Table of Contents
cfp_getln - find a configuration and return a line
#include <cfht/cfht.h>#include <cfht/cfp.h>char *cfp_getln(dest, key, name, suff)char
*dest;char *key;char *name;char *suff;
libcfht.a
This function
will search for the specified configuration file and then extract the information
from the specified line. The file can be read only and is closed when done.
Dest is the place where the results are to be stored. If NULL is passed
in, then internal space will be used. Key is the name of the line to find.
Name and suff are concatenated together to form the file name. NULL can
be used for either as appropriate.
Note that cfp_file() is used to find
the correct path of the desired file.
The return value is a
pointer to the found line or NULL if an error occurs.
To find out
the detector name:
"cfp_getln(name, CFHT_DETECTOR, CFHT_CONFNAME, NULL);"
- [EIO]
- something has gone wrong.
cfp(4)
.
If NULL is used
for dest, be sure to finish with the results before cfp_getln() is called
again.
Table of Contents