[Pkg-sysvinit-commits] r1093 - in sysvinit/trunk/debian: . patches
pere at alioth.debian.org
pere at alioth.debian.org
Sun Dec 23 18:05:27 UTC 2007
Author: pere
Date: 2007-12-23 18:05:27 +0000 (Sun, 23 Dec 2007)
New Revision: 1093
Added:
sysvinit/trunk/debian/patches/41_utmp_64bit.dpatch
Modified:
sysvinit/trunk/debian/changelog
sysvinit/trunk/debian/patches/00list
Log:
* New patch 41_utmp_64bit to avoid writing past the utmp.ut_vt
struct on 64 bit archtectures. Patch from Fedora.
Modified: sysvinit/trunk/debian/changelog
===================================================================
--- sysvinit/trunk/debian/changelog 2007-12-23 16:51:39 UTC (rev 1092)
+++ sysvinit/trunk/debian/changelog 2007-12-23 18:05:27 UTC (rev 1093)
@@ -22,6 +22,8 @@
runlevel" message. Based on patch from Fedora.
* Make sure the init waiting status is preserved across re-exec.
Patch from Fedora.
+ * New patch 41_utmp_64bit to avoid writing past the utmp.ut_vt
+ struct on 64 bit archtectures. Patch from Fedora.
-- Petter Reinholdtsen <pere at debian.org> Sun, 23 Dec 2007 10:03:48 +0100
Modified: sysvinit/trunk/debian/patches/00list
===================================================================
--- sysvinit/trunk/debian/patches/00list 2007-12-23 16:51:39 UTC (rev 1092)
+++ sysvinit/trunk/debian/patches/00list 2007-12-23 18:05:27 UTC (rev 1093)
@@ -12,6 +12,7 @@
30_strip
31_build_warnings
40_selinux
+41_utmp_64bit
45_pidof_symlink
50_bootlogd_exitcode
51_bootlogd_syncalot
Added: sysvinit/trunk/debian/patches/41_utmp_64bit.dpatch
===================================================================
--- sysvinit/trunk/debian/patches/41_utmp_64bit.dpatch (rev 0)
+++ sysvinit/trunk/debian/patches/41_utmp_64bit.dpatch 2007-12-23 18:05:27 UTC (rev 1093)
@@ -0,0 +1,50 @@
+#! /bin/sh /usr/share/dpatch/dpatch-run
+# 41_wtmp_64bit.dpatch by Petter Reinholdtsen
+
+The patch is a copy of sysvinit-2.86-timeval.patch from Fedora. It
+fixes utmp/wtmp updating of ut_addr_v6 on 64-bit platforms. See bug
+https://bugzilla.redhat.com/show_bug.cgi?id=176494
+
+ at DPATCH@
+--- 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
More information about the Pkg-sysvinit-commits
mailing list