mirror of
https://git.hardenedbsd.org/hardenedbsd/HardenedBSD.git
synced 2025-01-01 00:18:15 +01:00
Fixes:
If timed is running when system clock is changed by date command, improper wtmp entry is made. According to wtmp(5), two entries, one with "|" as ut_line field and one with "{" for ut_line, should be recorded, but, one with "|" and one with "}" are made. Closes: PR#bin/1182 Submitted by: Masafumi NAKANE <masafumi@tky007.tth.expo96.ad.jp>
This commit is contained in:
parent
ebcf24fb2b
commit
8c78c8f41c
@ -36,7 +36,7 @@ static char sccsid[] = "@(#)master.c 8.1 (Berkeley) 6/6/93";
|
||||
#endif /* not lint */
|
||||
|
||||
#ifdef sgi
|
||||
#ident "$Revision: 1.21 $"
|
||||
#ident "$Revision: 1.1.1.1 $"
|
||||
#endif
|
||||
|
||||
#include "globals.h"
|
||||
@ -390,7 +390,7 @@ mchgdate(msg)
|
||||
#else
|
||||
logwtmp("|", "date", "");
|
||||
(void)settimeofday(&msg->tsp_time, 0);
|
||||
logwtmp("}", "date", "");
|
||||
logwtmp("{", "date", "");
|
||||
#endif /* sgi */
|
||||
spreadtime();
|
||||
}
|
||||
|
@ -36,7 +36,7 @@ static char sccsid[] = "@(#)slave.c 8.1 (Berkeley) 6/6/93";
|
||||
#endif /* not lint */
|
||||
|
||||
#ifdef sgi
|
||||
#ident "$Revision: 1.20 $"
|
||||
#ident "$Revision: 1.1.1.1 $"
|
||||
#endif
|
||||
|
||||
#include "globals.h"
|
||||
@ -294,7 +294,7 @@ loop:
|
||||
#else
|
||||
logwtmp("|", "date", "");
|
||||
(void)settimeofday(&msg->tsp_time, 0);
|
||||
logwtmp("}", "date", "");
|
||||
logwtmp("{", "date", "");
|
||||
#endif /* sgi */
|
||||
syslog(LOG_NOTICE,
|
||||
"date changed by %s from %s",
|
||||
|
Loading…
Reference in New Issue
Block a user