[PATCH 1/2] No need to call endpwent()

From: Dimitris Papastamos <dimitris.papastamos_AT_arm.com>
Date: Fri, 7 Nov 2014 13:20:13 +0000

---
 slock.c | 2 --
 1 file changed, 2 deletions(-)
diff --git a/slock.c b/slock.c
index 399386b..d281965 100644
--- a/slock.c
+++ b/slock.c
_AT_@ -73,7 +73,6 @@ getpw(void) { /* only run as root */
 		else
 			die("slock: cannot retrieve password entry (make sure to suid or sgid slock)\n");
 	}
-	endpwent();
 	rval =  pw->pw_passwd;
 
 #if HAVE_SHADOW_H
_AT_@ -82,7 +81,6 @@ getpw(void) { /* only run as root */
 		sp = getspnam(getenv("USER"));
 		if(!sp)
 			die("slock: cannot retrieve shadow entry (make sure to suid or sgid slock)\n");
-		endspent();
 		rval = sp->sp_pwdp;
 	}
 #endif
-- 
1.8.4
--zYM0uCDKw75PZbzx--
Received on Mon Sep 17 2001 - 00:00:00 CEST

This archive was generated by hypermail 2.3.0 : Fri Nov 07 2014 - 14:24:07 CET