(print_expire): do not assume anything about the size of time_t,
i.e. make it 64-bit happy git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@8071 ec53bebd-3082-4978-b11e-865c3cabbd6b
This commit is contained in:
@@ -178,9 +178,9 @@ print_expire (krb5_context context,
|
|||||||
if (lr->val[i].lr_type == 6
|
if (lr->val[i].lr_type == 6
|
||||||
&& lr->val[i].lr_value <= t) {
|
&& lr->val[i].lr_value <= t) {
|
||||||
char *p;
|
char *p;
|
||||||
|
time_t = lr->val[i].lr_value;
|
||||||
|
|
||||||
asprintf (&p, "Your password will expire at %s",
|
asprintf (&p, "Your password will expire at %s", ctime(&t));
|
||||||
ctime(&lr->val[i].lr_value));
|
|
||||||
(*prompter) (context, data, p, 0, NULL);
|
(*prompter) (context, data, p, 0, NULL);
|
||||||
free (p);
|
free (p);
|
||||||
return;
|
return;
|
||||||
@@ -190,9 +190,9 @@ print_expire (krb5_context context,
|
|||||||
if (rep->enc_part.key_expiration
|
if (rep->enc_part.key_expiration
|
||||||
&& *rep->enc_part.key_expiration <= t) {
|
&& *rep->enc_part.key_expiration <= t) {
|
||||||
char *p;
|
char *p;
|
||||||
|
time_t t = *rep->enc_part.key_expiration;
|
||||||
|
|
||||||
asprintf (&p, "Your password/account will expire at %s",
|
asprintf (&p, "Your password/account will expire at %s", ctime(&t));
|
||||||
ctime(rep->enc_part.key_expiration));
|
|
||||||
(*prompter) (context, data, p, 0, NULL);
|
(*prompter) (context, data, p, 0, NULL);
|
||||||
free (p);
|
free (p);
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user