* src/chage.c: Cast 3rd date_to_str parameter to a time_t
This commit is contained in:
parent
05823ad867
commit
4049c0e69e
@ -14,6 +14,7 @@
|
||||
shadow_audit_result, use SHADOW_AUDIT_FAILURE instead of 0.
|
||||
* lib/selinux.c: vasprintf requires _GNU_SOURCE to be defined
|
||||
before including stdio.h.
|
||||
* src/chage.c: Cast 3rd date_to_str parameter to a time_t
|
||||
|
||||
2011-11-19 Nicolas François <nicolas.francois@centraliens.net>
|
||||
|
||||
|
@ -208,7 +208,7 @@ static int new_fields (void)
|
||||
if (-1 == lstchgdate) {
|
||||
strcpy (buf, "-1");
|
||||
} else {
|
||||
date_to_str (buf, sizeof buf, lstchgdate * SCALE);
|
||||
date_to_str (buf, sizeof buf, (time_t) lstchgdate * SCALE);
|
||||
}
|
||||
|
||||
change_field (buf, sizeof buf, _("Last Password Change (YYYY-MM-DD)"));
|
||||
@ -239,7 +239,7 @@ static int new_fields (void)
|
||||
if (-1 == expdate) {
|
||||
strcpy (buf, "-1");
|
||||
} else {
|
||||
date_to_str (buf, sizeof buf, expdate * SCALE);
|
||||
date_to_str (buf, sizeof buf, (time_t) expdate * SCALE);
|
||||
}
|
||||
|
||||
change_field (buf, sizeof buf,
|
||||
@ -679,8 +679,8 @@ static void update_age (/*@null@*/const struct spwd *sp,
|
||||
struct passwd pwent = *pw;
|
||||
|
||||
memzero (&spwent, sizeof spwent);
|
||||
spwent.sp_namp = xstrdup (pw->pw_name);
|
||||
spwent.sp_pwdp = xstrdup (pw->pw_passwd);
|
||||
spwent.sp_namp = xstrdup (pwent.pw_name);
|
||||
spwent.sp_pwdp = xstrdup (pwent.pw_passwd);
|
||||
spwent.sp_flag = SHADOW_SP_FLAG_UNSET;
|
||||
|
||||
pwent.pw_passwd = SHADOW_PASSWD_STRING; /* XXX warning: const */
|
||||
|
Loading…
Reference in New Issue
Block a user