diff options
author | Matthew Dillon <dillon@FreeBSD.org> | 2001-10-29 00:36:01 +0000 |
---|---|---|
committer | Matthew Dillon <dillon@FreeBSD.org> | 2001-10-29 00:36:01 +0000 |
commit | 2064ef1c81672461dfa2900e8546faecdce85ccb (patch) | |
tree | 78081699575afb3454f76c044f1451eded840dd4 /usr.sbin/ac/ac.c | |
parent | 5fb4dbe1a0dd2572c85d46bcff7d42505f9d37e7 (diff) | |
download | src-2064ef1c81672461dfa2900e8546faecdce85ccb.tar.gz src-2064ef1c81672461dfa2900e8546faecdce85ccb.zip |
localtime() was being called with an int-pointer due to recent utmp
fixes.
Notes
Notes:
svn path=/head/; revision=85649
Diffstat (limited to 'usr.sbin/ac/ac.c')
-rw-r--r-- | usr.sbin/ac/ac.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/usr.sbin/ac/ac.c b/usr.sbin/ac/ac.c index b82a7e72c9a2..1543568bd7ce 100644 --- a/usr.sbin/ac/ac.c +++ b/usr.sbin/ac/ac.c @@ -473,7 +473,8 @@ ac(fp) if (!FirstTime) FirstTime = usr.ut_time; if (Flags & AC_D) { - ltm = localtime(&usr.ut_time); + time_t t = int_to_time(usr.ut_time); + ltm = localtime(&t); if (day >= 0 && day != ltm->tm_yday) { day = ltm->tm_yday; /* @@ -524,7 +525,8 @@ ac(fp) (void)strcpy(usr.ut_line, "~"); if (Flags & AC_D) { - ltm = localtime(&usr.ut_time); + time_t t = int_to_time(usr.ut_time); + ltm = localtime(&t); if (day >= 0 && day != ltm->tm_yday) { /* * print yesterday's total |