diff options
author | Denis Vlasenko <vda.linux@googlemail.com> | 2008-08-03 18:43:45 +0000 |
---|---|---|
committer | Denis Vlasenko <vda.linux@googlemail.com> | 2008-08-03 18:43:45 +0000 |
commit | 1e28f6171fe9cb56422473d506aa28fdb1eb46d8 (patch) | |
tree | edf9401b4fa49a9b75f3d6c1141b23254b9842e2 /init | |
parent | cfe2936a73a286aee8f8b0336212e996ad4d9f95 (diff) | |
download | busybox-w32-1e28f6171fe9cb56422473d506aa28fdb1eb46d8.tar.gz busybox-w32-1e28f6171fe9cb56422473d506aa28fdb1eb46d8.tar.bz2 busybox-w32-1e28f6171fe9cb56422473d506aa28fdb1eb46d8.zip |
halt: signal init regardless of ENABLE_INIT
Diffstat (limited to 'init')
-rw-r--r-- | init/halt.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/init/halt.c b/init/halt.c index 7e1b30f39..8c1f30b08 100644 --- a/init/halt.c +++ b/init/halt.c | |||
@@ -34,7 +34,7 @@ RB_AUTOBOOT | |||
34 | static const smallint signals[] = { SIGUSR1, SIGUSR2, SIGTERM }; | 34 | static const smallint signals[] = { SIGUSR1, SIGUSR2, SIGTERM }; |
35 | 35 | ||
36 | int delay = 0; | 36 | int delay = 0; |
37 | int which, flags, rc = 1; | 37 | int which, flags, rc; |
38 | #if ENABLE_FEATURE_WTMP | 38 | #if ENABLE_FEATURE_WTMP |
39 | struct utmp utmp; | 39 | struct utmp utmp; |
40 | struct utsname uts; | 40 | struct utsname uts; |
@@ -71,7 +71,10 @@ RB_AUTOBOOT | |||
71 | sync(); | 71 | sync(); |
72 | 72 | ||
73 | /* Perform action. */ | 73 | /* Perform action. */ |
74 | if (ENABLE_INIT && !(flags & 4)) { /* no -f */ | 74 | rc = 1; |
75 | if (!(flags & 4)) { /* no -f */ | ||
76 | //TODO: I tend to think that signalling linuxrc is wrong | ||
77 | // pity original author didn't comment on it... | ||
75 | if (ENABLE_FEATURE_INITRD) { | 78 | if (ENABLE_FEATURE_INITRD) { |
76 | pid_t *pidlist = find_pid_by_name("linuxrc"); | 79 | pid_t *pidlist = find_pid_by_name("linuxrc"); |
77 | if (pidlist[0] > 0) | 80 | if (pidlist[0] > 0) |