[Pkg-shadow-commits] r2709 - in upstream/trunk: . libmisc
Nicolas FRANÇOIS
nekral-guest at alioth.debian.org
Sun Apr 19 15:28:38 UTC 2009
Author: nekral-guest
Date: 2009-04-19 15:28:38 +0000 (Sun, 19 Apr 2009)
New Revision: 2709
Modified:
upstream/trunk/ChangeLog
upstream/trunk/libmisc/utmp.c
Log:
* libmisc/utmp.c: Always call endutent or endutxent when setutent
or setutxent were used.
Modified: upstream/trunk/ChangeLog
===================================================================
--- upstream/trunk/ChangeLog 2009-04-19 13:33:24 UTC (rev 2708)
+++ upstream/trunk/ChangeLog 2009-04-19 15:28:38 UTC (rev 2709)
@@ -1,3 +1,8 @@
+2009-04-19 Paul Szabo <psz at maths.usyd.edu.au>
+
+ * libmisc/utmp.c: Always call endutent or endutxent when setutent
+ or setutxent were used.
+
2009-04-19 Nicolas François <nicolas.francois at centraliens.net>
* src/login.c: Added comment to make sure PAM_RHOST or PAM_TTY do
Modified: upstream/trunk/libmisc/utmp.c
===================================================================
--- upstream/trunk/libmisc/utmp.c 2009-04-19 13:33:24 UTC (rev 2708)
+++ upstream/trunk/libmisc/utmp.c 2009-04-19 15:28:38 UTC (rev 2709)
@@ -148,6 +148,8 @@
/* Sanitize / set the ut_line field */
strncpy (utent.ut_line, line, sizeof utent.ut_line);
+
+ endutent ();
}
#elif defined(LOGIN_PROCESS)
@@ -269,6 +271,11 @@
utent.ut_time = utxent.ut_tv.tv_sec;
#endif
}
+
+#if HAVE_UTMPX_H
+ endutxent ();
+#endif
+ endutent ();
}
#endif
@@ -442,6 +449,9 @@
utxent = utxline;
utent = utline;
+ endutxent ();
+ endutent ();
+
return err;
}
More information about the Pkg-shadow-commits
mailing list