[Pkg-shadow-commits] r2149 - in upstream/trunk: . src

nekral-guest at alioth.debian.org nekral-guest at alioth.debian.org
Fri Jun 13 20:33:39 UTC 2008


Author: nekral-guest
Date: 2008-06-13 20:33:38 +0000 (Fri, 13 Jun 2008)
New Revision: 2149

Modified:
   upstream/trunk/ChangeLog
   upstream/trunk/src/pwconv.c
Log:
	* src/pwconv.c: Use SHADOW_SP_FLAG_UNSET for the initial
	value of sp.sp_flag.
	* src/pwconv.c: Cast number of days to a long integer.


Modified: upstream/trunk/ChangeLog
===================================================================
--- upstream/trunk/ChangeLog	2008-06-13 20:29:58 UTC (rev 2148)
+++ upstream/trunk/ChangeLog	2008-06-13 20:33:38 UTC (rev 2149)
@@ -1,5 +1,11 @@
 2008-06-13  Nicolas François  <nicolas.francois at centraliens.net>
 
+	* src/pwconv.c: Use SHADOW_SP_FLAG_UNSET for the initial
+	value of sp.sp_flag.
+	* src/pwconv.c: Cast number of days to a long integer.
+
+2008-06-13  Nicolas François  <nicolas.francois at centraliens.net>
+
 	* src/gpasswd.c: The ID argument of audit_logger is an unsigned
 	int.
 	* src/gpasswd.c: Ignore the return value of signal(). The signal

Modified: upstream/trunk/src/pwconv.c
===================================================================
--- upstream/trunk/src/pwconv.c	2008-06-13 20:29:58 UTC (rev 2148)
+++ upstream/trunk/src/pwconv.c	2008-06-13 20:33:38 UTC (rev 2149)
@@ -170,16 +170,16 @@
 		} else {
 			/* add new shadow entry */
 			memset (&spent, 0, sizeof spent);
-			spent.sp_namp = pw->pw_name;
-			spent.sp_min = getdef_num ("PASS_MIN_DAYS", -1);
-			spent.sp_max = getdef_num ("PASS_MAX_DAYS", -1);
-			spent.sp_warn = getdef_num ("PASS_WARN_AGE", -1);
-			spent.sp_inact = -1;
+			spent.sp_namp   = pw->pw_name;
+			spent.sp_min    = getdef_num ("PASS_MIN_DAYS", -1);
+			spent.sp_max    = getdef_num ("PASS_MAX_DAYS", -1);
+			spent.sp_warn   = getdef_num ("PASS_WARN_AGE", -1);
+			spent.sp_inact  = -1;
 			spent.sp_expire = -1;
-			spent.sp_flag = -1;
+			spent.sp_flag   = SHADOW_SP_FLAG_UNSET;
 		}
 		spent.sp_pwdp = pw->pw_passwd;
-		spent.sp_lstchg = time ((time_t *) 0) / (24L * 3600L);
+		spent.sp_lstchg = (long) time ((time_t *) 0) / SCALE;
 		if (spw_update (&spent) == 0) {
 			fprintf (stderr,
 				 _




More information about the Pkg-shadow-commits mailing list