sysupgrade: do not kill any processes in failsafe
[openwrt/openwrt.git] / package / base-files / files / sbin / sysupgrade
index 56e9a92424556d8a981e3f313561becaf6228e3e..e6588bffcf61d0ae5cb906011ac32fa99283cb45 100755 (executable)
@@ -210,9 +210,11 @@ run_hooks "" $sysupgrade_pre_upgrade
 ubus call system upgrade
 touch /tmp/sysupgrade
 
-kill_remaining TERM
-sleep 3
-kill_remaining KILL
+if [ ! -f /tmp/failsafe ] ; then
+       kill_remaining TERM
+       sleep 3
+       kill_remaining KILL
+fi
 
 if [ -n "$(rootfs_type)" ]; then
        v "Switching to ramdisk..."