COHERENT manpages
This page displays the COHERENT manpage for getutline() [Find a record in login logging file by device].
List of available manpages
Index
getutline() -- General Function (libc) Find a record in login logging file by device #include <utmp.h> struct utmp *getutline(line) struct utmp *line; Function getutline() seeks a record for a login that occurred for a given line. line points to an object of type utmp, which is a structure whose fields describe a login event. (For a detailed description of this structure, see the Lexicon entry for utmp.h.) Before you call getutline(), you must initialize field line.ut_line to the name of the device that interests you. If it finds a record that matches your request, getutline() copies it into a static portion of memory and returns the address of that memory. It returns NULL if it fails to find a record for the device you named, or if it cannot open the login file. By default, getutline() reads records from /etc/utmp. If you wish to read records from another file, call utmpname() before you call getutid(). See Also libc, utmp.h