Remove unneeded setpassent() calls.

lastlogin no longer requires the use of the passwd database.
This commit is contained in:
Ed Schouten 2010-01-24 14:29:40 +00:00
parent 629b054a63
commit 3c247358fe

View File

@ -37,7 +37,6 @@ __RCSID("$NetBSD: lastlogin.c,v 1.4 1998/02/03 04:45:35 perry Exp $");
#endif
#include <err.h>
#include <pwd.h>
#include <stdio.h>
#include <stdlib.h>
#include <time.h>
@ -58,8 +57,6 @@ main(int argc, char *argv[])
usage();
}
setpassent(1); /* Keep passwd file pointers open */
/* Process usernames given on the command line. */
if (argc > 1) {
for (i = 1; i < argc; ++i) {
@ -85,7 +82,6 @@ main(int argc, char *argv[])
endutxent();
}
setpassent(0); /* Close passwd file pointers */
exit(0);
}