#include <utmp.h> void logwtmp(const char *line, const char *name, const char *host); |
logwtmp() constructs an utmp structure using line, name, host, current time and current process id. Then it calls updwtmp() to append the structure to the utmp file.