ALT Linux Bugzilla
– Attachment 574 Details for
Bug 5091
[x86_64] pam_lastlog: ctime return null in last_login_date.
New bug
|
Search
|
[?]
|
Help
Register
|
Log In
[x]
|
Forgot Password
Login:
[x]
|
EN
|
RU
[patch]
patch for pam_lastlog module
pam_lastlog.c.diff (text/plain), 1.45 KB, created by
Kachalov Anton
on 2004-08-30 01:15:13 MSD
(
hide
)
Description:
patch for pam_lastlog module
Filename:
MIME Type:
Creator:
Kachalov Anton
Created:
2004-08-30 01:15:13 MSD
Size:
1.45 KB
patch
obsolete
>Index: modules/pam_lastlog/pam_lastlog.c >=================================================================== >RCS file: /cvsroot/pam/Linux-PAM/modules/pam_lastlog/pam_lastlog.c,v >retrieving revision 1.4 >retrieving revision 1.5 >diff -u -u -r1.4 -r1.5 >--- modules/pam_lastlog/pam_lastlog.c 12 Oct 2001 05:56:26 -0000 1.4 >+++ modules/pam_lastlog/pam_lastlog.c 25 Nov 2003 09:00:06 -0000 1.5 >@@ -1,7 +1,7 @@ > /* pam_lastlog module */ > > /* >- * $Id: pam_lastlog.c,v 1.4 2001/10/12 05:56:26 agmorgan Exp $ >+ * $Id: pam_lastlog.c,v 1.5 2003/11/25 09:00:06 kukuk Exp $ > * > * Written by Andrew Morgan <morgan@linux.kernel.org> 1996/3/11 > * >@@ -254,10 +254,12 @@ > > if (!(announce & LASTLOG_QUIET)) { > if (last_login.ll_time) { >+ time_t ll_time; > char *the_time; > char *remark; > >- the_time = ctime(&last_login.ll_time); >+ ll_time = last_login.ll_time; >+ the_time = ctime(&ll_time); > the_time[-1+strlen(the_time)] = '\0'; /* delete '\n' */ > > remark = malloc(LASTLOG_MAXSIZE); >@@ -319,13 +321,15 @@ > > /* write latest value */ > { >+ time_t ll_time; > const char *remote_host=NULL > , *terminal_line=DEFAULT_TERM; > > /* set this login date */ > D(("set the most recent login time")); > >- (void) time(&last_login.ll_time); /* set the time */ >+ (void) time(&ll_time); /* set the time */ >+ last_login.ll_time = ll_time; > > /* set the remote host */ > (void) pam_get_item(pamh, PAM_RHOST, (const void **)&remote_host);
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 5091
: 574