diff options
author | andersen <andersen@69ca8d6d-28ef-0310-b511-8ec308f3f277> | 2004-07-24 12:44:13 +0000 |
---|---|---|
committer | andersen <andersen@69ca8d6d-28ef-0310-b511-8ec308f3f277> | 2004-07-24 12:44:13 +0000 |
commit | 9d39a896a95f562a8229c88ed1fdeaa929a06010 (patch) | |
tree | 866073ca8827635be139b378fe30d17acc853165 /shell | |
parent | 9dd6d8cdf3448900aced2e81ef5a7f31edcb3a3f (diff) | |
download | busybox-w32-9d39a896a95f562a8229c88ed1fdeaa929a06010.tar.gz busybox-w32-9d39a896a95f562a8229c88ed1fdeaa929a06010.tar.bz2 busybox-w32-9d39a896a95f562a8229c88ed1fdeaa929a06010.zip |
Paul Whittaker writes:
With job control enabled, ash fails to tcsetpgrp back to initialpgrp
upon exit. exitshell() should call setjobctl(0) to do this.
Context: I am using a lightweight menu system (replimenu[.sf.net]) on my
console, which invokes "/bin/sh -i -c /bin/login", where /bin/sh and
/bin/login are busybox applets. /bin/sh is ash, with
CONFIG_ASH_JOB_CONTROL=y as the sole suboption. The shell of the user
concerned (nobody) is also /bin/sh (ash). When the user /bin/sh exits
(and thereby login and its parent sh), replimenu receives EIO when it
tries to read from the terminal.
git-svn-id: svn://busybox.net/trunk/busybox@9013 69ca8d6d-28ef-0310-b511-8ec308f3f277
Diffstat (limited to 'shell')
-rw-r--r-- | shell/ash.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/shell/ash.c b/shell/ash.c index fd616ef4a..ee3bfb42f 100644 --- a/shell/ash.c +++ b/shell/ash.c | |||
@@ -11914,6 +11914,7 @@ exitshell(void) | |||
11914 | evalstring(p); | 11914 | evalstring(p); |
11915 | } | 11915 | } |
11916 | flushall(); | 11916 | flushall(); |
11917 | setjobctl(0); | ||
11917 | #ifdef CONFIG_FEATURE_COMMAND_SAVEHISTORY | 11918 | #ifdef CONFIG_FEATURE_COMMAND_SAVEHISTORY |
11918 | if (iflag && rootshell) { | 11919 | if (iflag && rootshell) { |
11919 | const char *hp = lookupvar("HISTFILE"); | 11920 | const char *hp = lookupvar("HISTFILE"); |