[BusyBox] patch: don't try to run swapoff on halt/reboot when swapon/off is not compiled into busybox

Milan Svoboda msvoboda at ra.rockwell.com
Tue Dec 21 12:35:55 UTC 2004


Hello,
        this is patch against Busybox-1.00.

Best regards
 Milan Svoboda


--- init-old.c  2004-10-08 10:21:54.000000000 +0200
+++ init.c      2004-12-21 13:11:31.136591100 +0100
@@ -960,7 +960,7 @@
        new_init_action(CTRLALTDEL, "/sbin/reboot", "");
        /* Umount all filesystems on halt/reboot */
        new_init_action(SHUTDOWN, "/bin/umount -a -r", "");
-#if !defined(__UCLIBC__) || defined(__ARCH_HAS_MMU__)
+#if defined(CONFIG_SWAPONOFF) && (!defined(__UCLIBC__) || 
defined(__ARCH_HAS_MMU__))
        /* Swapoff on halt/reboot */
        new_init_action(SHUTDOWN, "/sbin/swapoff -a", "");
 #endif



More information about the busybox mailing list