[Pkg-sysvinit-commits] r812 - in sysvinit/trunk/debian: . patches
Petter Reinholdtsen
pere at costa.debian.org
Wed Jul 26 16:41:31 UTC 2006
Author: pere
Date: 2006-07-26 16:41:30 +0000 (Wed, 26 Jul 2006)
New Revision: 812
Added:
sysvinit/trunk/debian/patches/66_init_emerg_tty.dpatch
Modified:
sysvinit/trunk/debian/changelog
sysvinit/trunk/debian/patches/00list
Log:
* Fix emergency mode's tty, making sure ^C and ^Z work when booting
with 'emergency' kernel option. Patch from Samuel
Thibault. (Closes: #374543)
Modified: sysvinit/trunk/debian/changelog
===================================================================
--- sysvinit/trunk/debian/changelog 2006-07-25 17:50:04 UTC (rev 811)
+++ sysvinit/trunk/debian/changelog 2006-07-26 16:41:30 UTC (rev 812)
@@ -1,3 +1,11 @@
+sysvinit (2.86.ds1-16~1) unstable; urgency=low
+
+ * Fix emergency mode's tty, making sure ^C and ^Z work when booting
+ with 'emergency' kernel option. Patch from Samuel
+ Thibault. (Closes: #374543)
+
+ -- Petter Reinholdtsen <pere at debian.org> Wed, 26 Jul 2006 11:37:23 +0200
+
sysvinit (2.86.ds1-15) unstable; urgency=low
[ Petter Reinholdtsen ]
Modified: sysvinit/trunk/debian/patches/00list
===================================================================
--- sysvinit/trunk/debian/patches/00list 2006-07-25 17:50:04 UTC (rev 811)
+++ sysvinit/trunk/debian/patches/00list 2006-07-26 16:41:30 UTC (rev 812)
@@ -24,6 +24,7 @@
63_init_longer_procname
64_init_set_PATH
65_init_u_in_06
+66_init_emerg_tty
70_wall_ttyname
71_wall_hostname
80_killall_sched
Added: sysvinit/trunk/debian/patches/66_init_emerg_tty.dpatch
===================================================================
--- sysvinit/trunk/debian/patches/66_init_emerg_tty.dpatch 2006-07-25 17:50:04 UTC (rev 811)
+++ sysvinit/trunk/debian/patches/66_init_emerg_tty.dpatch 2006-07-26 16:41:30 UTC (rev 812)
@@ -0,0 +1,58 @@
+#! /bin/sh /usr/share/dpatch/dpatch-run
+## 66_init_ermg_tty.dpatch by Samuel Thibault
+##
+## All lines beginning with `## DP:' are a description of the patch.
+## DP: Fix emergency mode's tty, making sure ^C and ^Z work when
+## DP: booting with 'emergency' kernel option. Closes bug #374543.
+
+ at DPATCH@
+Index: sysvinit/src/init.c
+===================================================================
+--- sysvinit/src/init.c (revisjon 808)
++++ sysvinit/src/init.c (arbeidskopi)
+@@ -89,7 +89,7 @@
+ CHILD *newFamily = NULL; /* The list after inittab re-read */
+
+ CHILD ch_emerg = { /* Emergency shell */
+- 0, 0, 0, 0, 0,
++ WAITING, 0, 0, 0, 0,
+ "~~",
+ "S",
+ 3,
+Index: sysvinit/src/sulogin.c
+===================================================================
+--- sysvinit/src/sulogin.c (revisjon 808)
++++ sysvinit/src/sulogin.c (arbeidskopi)
+@@ -23,6 +23,7 @@
+ #include <pwd.h>
+ #include <shadow.h>
+ #include <termios.h>
++#include <errno.h>
+ #include <sys/ioctl.h>
+ #if defined(__GLIBC__)
+ # include <crypt.h>
+@@ -410,7 +411,6 @@
+ if (pid != getsid(0)) {
+ if (pid == getpgid(0))
+ setpgid(0, getpgid(getppid()));
+- setsid();
+ }
+
+ signal(SIGHUP, SIG_IGN);
+@@ -421,13 +421,15 @@
+ close(2);
+ close(fd);
+ fd = open(tty, O_RDWR);
+- ioctl(0, TIOCSCTTY, (char *)1);
+ dup(fd);
+ dup(fd);
+ } else
+ close(fd);
+ }
+ }
++ setsid();
++ if (ioctl(0, TIOCSCTTY, (char *)1))
++ perror("ioctl(TIOCSCTTY)");
+
+ /*
+ * Get the root password.
More information about the Pkg-sysvinit-commits
mailing list