/* Get the next entry from the user accounting database. */ struct utmpx32 * getutxent32 (void) { struct utmpx *out64; ALLOCATE_UTMPX32_OUT (out32); out64 = __getutxent (); if (!out64) return NULL; utmpx_convert64to32 (out64, out32); return out32; }
struct utmpx * getutxline (const struct utmpx *line) { for (;;) { struct utmpx *next = __getutxent (); if (next == NULL) return NULL; if ((next->ut_type == LOGIN_PROCESS || next->ut_type == USER_PROCESS) && strncmp (next->ut_line, line->ut_line, __UT_LINESIZE) == 0) return next; } }