home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
GEMini Atari
/
GEMini_Atari_CD-ROM_Walnut_Creek_December_1993.iso
/
files
/
mint
/
init_5
/
utmp.h
< prev
next >
Wrap
C/C++ Source or Header
|
1993-08-03
|
524b
|
23 lines
/*
* Structure of utmp and wtmp files.
*
*/
struct utmp {
char ut_line[8]; /* tty name */
char ut_name[8]; /* user id */
char ut_host[16]; /* host name, if remote */
long ut_time; /* time on */
};
/*
* This is to determine if a utmp entry does not correspond to a genuine user
* (pseudo tty)
*/
#define nonuser(ut) ((ut).ut_host[0] == 0 && \
strncmp((ut).ut_line, "tty", 3) == 0 \
&& ((ut).ut_line[3] == 'p' \
|| (ut).ut_line[3] == 'q' \
|| (ut).ut_line[3] == 'r' \
|| (ut).ut_line[3] == 's'))