svn commit: [26075] trunk/busybox/init
vda at busybox.net
vda at busybox.net
Sun Apr 12 15:59:36 UTC 2009
Author: vda
Date: 2009-04-12 15:59:35 +0000 (Sun, 12 Apr 2009)
New Revision: 26075
Log:
halt/reboot/powerdown: accept and ignore -i
Modified:
trunk/busybox/init/halt.c
Changeset:
Modified: trunk/busybox/init/halt.c
===================================================================
--- trunk/busybox/init/halt.c 2009-04-12 14:21:29 UTC (rev 26074)
+++ trunk/busybox/init/halt.c 2009-04-12 15:59:35 UTC (rev 26075)
@@ -63,9 +63,11 @@
/* Parse and handle arguments */
opt_complementary = "d+"; /* -d N */
- /* We support -w even if !ENABLE_FEATURE_WTMP, in order
- * to not break scripts */
- flags = getopt32(argv, "d:nfw", &delay);
+ /* We support -w even if !ENABLE_FEATURE_WTMP,
+ * in order to not break scripts.
+ * -i (shut down network interfaces) is ignored.
+ */
+ flags = getopt32(argv, "d:nfwi", &delay);
sleep(delay);
@@ -89,10 +91,12 @@
if (ENABLE_FEATURE_CLEAN_UP)
free(pidlist);
}
- if (rc)
+ if (rc) {
rc = kill(1, signals[which]);
- } else
+ }
+ } else {
rc = reboot(magic[which]);
+ }
if (rc)
bb_perror_nomsg_and_die();
More information about the busybox-cvs
mailing list