diff options
author | landley <landley@69ca8d6d-28ef-0310-b511-8ec308f3f277> | 2006-05-23 00:28:06 +0000 |
---|---|---|
committer | landley <landley@69ca8d6d-28ef-0310-b511-8ec308f3f277> | 2006-05-23 00:28:06 +0000 |
commit | 79aab570afcc7259fe6526a6acbe9b2b85ee1072 (patch) | |
tree | 12fcf73c4de8647c130706bc7ef78ce281fa3f61 | |
parent | 3a19c5834aa26be8b377c712d043e71a092252ab (diff) | |
download | busybox-w32-79aab570afcc7259fe6526a6acbe9b2b85ee1072.tar.gz busybox-w32-79aab570afcc7259fe6526a6acbe9b2b85ee1072.tar.bz2 busybox-w32-79aab570afcc7259fe6526a6acbe9b2b85ee1072.zip |
It takes _talent_ to implement a version of nohup that does everything except
the actual blocking of HUP.
git-svn-id: svn://busybox.net/trunk/busybox@15159 69ca8d6d-28ef-0310-b511-8ec308f3f277
-rw-r--r-- | coreutils/nohup.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/coreutils/nohup.c b/coreutils/nohup.c index ea1c4c55a..50f54cca6 100644 --- a/coreutils/nohup.c +++ b/coreutils/nohup.c | |||
@@ -10,6 +10,7 @@ | |||
10 | */ | 10 | */ |
11 | 11 | ||
12 | #include <fcntl.h> | 12 | #include <fcntl.h> |
13 | #include <signal.h> | ||
13 | #include <unistd.h> | 14 | #include <unistd.h> |
14 | #include "busybox.h" | 15 | #include "busybox.h" |
15 | 16 | ||
@@ -44,8 +45,8 @@ int nohup_main(int argc, char *argv[]) | |||
44 | temp = isatty(2); | 45 | temp = isatty(2); |
45 | if (temp) fdprintf(2,"Writing to %s\n", home ? home : nohupout); | 46 | if (temp) fdprintf(2,"Writing to %s\n", home ? home : nohupout); |
46 | dup2(temp ? 1 : nullfd, 2); | 47 | dup2(temp ? 1 : nullfd, 2); |
47 | |||
48 | close(nullfd); | 48 | close(nullfd); |
49 | signal (SIGHUP, SIG_IGN); | ||
49 | 50 | ||
50 | // Exec our new program. | 51 | // Exec our new program. |
51 | 52 | ||