diff options
Diffstat (limited to 'login/getutline_r.c')
-rw-r--r-- | login/getutline_r.c | 10 |
1 files changed, 2 insertions, 8 deletions
diff --git a/login/getutline_r.c b/login/getutline_r.c index a1bdc0b..5733594 100644 --- a/login/getutline_r.c +++ b/login/getutline_r.c @@ -20,8 +20,6 @@ #include <errno.h> #include <bits/libc-lock.h> -#include <string.h> -#include <unistd.h> #include <utmp.h> #include "utmp-private.h" @@ -38,15 +36,11 @@ int __getutline_r (const struct utmp *line, struct utmp *buffer, struct utmp **result) { - int retval = -1; + int retval; __libc_lock_lock (__libc_utmp_lock); - /* Not yet initialized. */ - if ((*__libc_utmp_jump_table->setutent) ()) - retval = (*__libc_utmp_jump_table->getutline_r) (line, buffer, result); - else - *result = NULL; + retval = (*__libc_utmp_jump_table->getutline_r) (line, buffer, result); __libc_lock_unlock (__libc_utmp_lock); |