Browse Source

At boot, the startup process is executed in a non-interactive shell. Default behavior for a non-interactive shell is that SIGINT is processeld locally by the shell (and typically ignored), this runtime environment is inherited by children, hence Ctrl-C has no effect within a telnet session. This patch enables the correct behavior

SVN-Revision: 18088
Hamish Guthrie 16 years ago
parent
commit
c724a69355
1 changed files with 12 additions and 0 deletions
  1. 12 0
      package/busybox/patches/902-telnetd_intr.patch

+ 12 - 0
package/busybox/patches/902-telnetd_intr.patch

@@ -0,0 +1,12 @@
+diff --git a/networking/telnetd.c b/networking/telnetd.c
+index 2a0ace5..c281feb 100644
+--- a/networking/telnetd.c
++++ b/networking/telnetd.c
+@@ -308,6 +308,7 @@ make_new_session(
+ 
+ 	/* Restore default signal handling ASAP */
+ 	bb_signals((1 << SIGCHLD) + (1 << SIGPIPE), SIG_DFL);
++	signal(SIGINT, SIG_DFL);
+ 
+ 	/* Make new session and process group */
+ 	setsid();