1 .\" Generated from openpam_readlinev.c by gendoc.pl
2 .\" $Id: openpam_readlinev.c 648 2013-03-05 17:54:27Z des $
4 .Dt OPENPAM_READLINEV 3
8 .Nd read a line from a file and split it into words
14 .In security/pam_appl.h
15 .In security/openpam.h
17 .Fn openpam_readlinev "FILE *f" "int *lineno" "int *lenp"
21 function reads a line from a file, splits it
22 into words according to the rules described in the
23 .Xr openpam_readword 3
24 manual page, and returns a list of those words.
30 the integer variable it points to is
31 incremented every time a newline character is read.
32 This includes quoted or escaped newline characters and the newline
33 character at the end of the line.
39 the number of words on the line is stored in the
40 variable to which it points.
44 function returns a pointer to a
45 dynamically allocated array of pointers to individual dynamically
46 allocated NUL-terminated strings, each containing a single word, in the
47 order in which they were encountered on the line.
48 The array is terminated by a
52 The caller is responsible for freeing both the array and the individual
53 strings by passing each of them to
56 If the end of the line was reached before any words were read,
58 returns a pointer to a dynamically allocated array
65 function can fail and return
71 The end of the file was reached before any words were read;
78 returns a non-zero value.
80 The end of the file was reached while a quote or backslash escape
88 returns a non-zero value.
90 An error occurred while reading from the file;
94 returns a non-zero value and
107 returns a non-zero value, and
109 may or may not return
113 .Xr openpam_readline 3 ,
114 .Xr openpam_readword 3 ,
118 .Fn openpam_readlinev
119 function is an OpenPAM extension.
122 .Fn openpam_readlinev
123 function and this manual page were
125 .An Dag-Erling Sm\(/orgrav Aq des@des.no .