Blame SOURCES/telnet-rh825946.patch

3521ef
diff -up netkit-telnet-0.17/telnetd/sys_term.c.rh825946 netkit-telnet-0.17/telnetd/sys_term.c
3521ef
--- netkit-telnet-0.17/telnetd/sys_term.c.rh825946	1999-12-17 15:28:47.000000000 +0100
3521ef
+++ netkit-telnet-0.17/telnetd/sys_term.c	2012-06-14 14:05:30.538342755 +0200
3521ef
@@ -723,6 +723,9 @@ void cleanup(int sig) {
3521ef
     char *p;
3521ef
     (void)sig;
3521ef
 
3521ef
+    /* to avoid a race for wtmp lock */
3521ef
+    signal(SIGCHLD, SIG_IGN);
3521ef
+
3521ef
     p = line + sizeof("/dev/") - 1;
3521ef
     if (logout(p)) logwtmp(p, "", "");
3521ef
 #ifdef PARANOID_TTYS
3521ef
diff -up netkit-telnet-0.17/telnetd/telnetd.c.rh825946 netkit-telnet-0.17/telnetd/telnetd.c
3521ef
--- netkit-telnet-0.17/telnetd/telnetd.c.rh825946	2012-06-14 14:04:42.000000000 +0200
3521ef
+++ netkit-telnet-0.17/telnetd/telnetd.c	2012-06-14 14:06:01.547291404 +0200
3521ef
@@ -1147,8 +1147,6 @@ void telnet(int f, int p)
3521ef
 	if (FD_ISSET(p, &obits) && (pfrontp - pbackp) > 0)
3521ef
 	    ptyflush();
3521ef
     }
3521ef
-    /* to avoid a race for wtmp lock */
3521ef
-    signal(SIGCHLD, SIG_IGN);
3521ef
     cleanup(0);
3521ef
 }  /* end of telnet */
3521ef