rpms/SysVinit/devel sysvinit-2.86-timeval.patch, NONE, 1.1 SysVinit.spec, 1.48, 1.49
fedora-cvs-commits at redhat.com
fedora-cvs-commits at redhat.com
Thu Aug 10 00:02:40 UTC 2006
Author: notting
Update of /cvs/dist/rpms/SysVinit/devel
In directory cvs.devel.redhat.com:/tmp/cvs-serv970
Modified Files:
SysVinit.spec
Added Files:
sysvinit-2.86-timeval.patch
Log Message:
fix utmp records on x86_64 (#176494)
sysvinit-2.86-timeval.patch:
utmp.c | 12 +++++++++---
1 files changed, 9 insertions(+), 3 deletions(-)
--- NEW FILE sysvinit-2.86-timeval.patch ---
--- sysvinit-2.86/src/utmp.c.timeval 1999-06-09 07:11:33.000000000 -0400
+++ sysvinit-2.86/src/utmp.c 2006-08-09 19:46:26.000000000 -0400
@@ -47,7 +47,8 @@
int fd;
struct utmp utmp;
struct utsname uname_buf;
-
+ struct timeval tv;
+
/*
* Try to open the wtmp file. Note that we even try
* this if we have updwtmp() so we can see if the
@@ -76,7 +77,9 @@
*/
memset(&utmp, 0, sizeof(utmp));
#if defined(__GLIBC__)
- gettimeofday(&utmp.ut_tv, NULL);
+ gettimeofday(&tv, NULL);
+ utmp.ut_tv.tv_sec = tv.tv_sec;
+ utmp.ut_tv.tv_usec = tv.tv_usec;
#else
time(&utmp.ut_time);
#endif
@@ -113,6 +116,7 @@
struct utmp utmp;
struct utmp tmp;
struct utmp *utmptr;
+ struct timeval tv;
/*
* Can't do much if UTMP_FILE is not present.
@@ -144,7 +148,9 @@
utmp.ut_pid = pid;
strncpy(utmp.ut_id, id, sizeof(utmp.ut_id));
#if defined(__GLIBC__)
- gettimeofday(&utmp.ut_tv, NULL);
+ gettimeofday(&tv, NULL);
+ utmp.ut_tv.tv_sec = tv.tv_sec;
+ utmp.ut_tv.tv_usec = tv.tv_usec;
#else
time(&utmp.ut_time);
#endif
Index: SysVinit.spec
===================================================================
RCS file: /cvs/dist/rpms/SysVinit/devel/SysVinit.spec,v
retrieving revision 1.48
retrieving revision 1.49
diff -u -r1.48 -r1.49
--- SysVinit.spec 9 Aug 2006 19:11:52 -0000 1.48
+++ SysVinit.spec 10 Aug 2006 00:02:36 -0000 1.49
@@ -1,7 +1,7 @@
Summary: Programs which control basic system processes.
Name: SysVinit
Version: 2.86
-Release: 8
+Release: 9
License: GPL
Group: System Environment/Base
Source: ftp://ftp.cistron.nl/pub/people/miquels/sysvinit/sysvinit-%{version}.tar.gz
@@ -22,6 +22,7 @@
Patch15: sysvinit-2.86-ipv6.patch
Patch16: sysvinit-2.86-quiet.patch
Patch17: sysvinit-2.86-godot.patch
+Patch18: sysvinit-2.86-timeval.patch
Patch20: sysvinit-selinux.patch
Source1: change_console.c
Source2: change_console.8
@@ -77,6 +78,8 @@
%patch16 -p1 -b .quiet
# Preserve 'waiting' across re-exec (#199305, #201146, #143289)
%patch17 -p1 -b .godot
+# Don't overwrite ut_addr_v6 on 64-bit platforms (#176494)
+%patch18 -p1 -b .timeval
# SELinux support for init - loading policy, etc.
%patch20 -p1 -b .selinux
@@ -139,6 +142,7 @@
* Wed Aug 9 2006 Bill Nottingham <notting at redhat.com> - 2.86-8
- preserve 'WAITING' across re-exec (#143289, others)
- actually apply quiet patch
+- don't write garbage to utmp on x86-64 (#176494)
* Tue Aug 8 2006 Bill Nottingham <notting at redhat.com> - 2.86-7
- be slightly less verbose when booted with 'quiet'
More information about the fedora-cvs-commits
mailing list