aboutsummaryrefslogtreecommitdiffstats
path: root/package
diff options
context:
space:
mode:
Diffstat (limited to 'package')
-rwxr-xr-xpackage/base-files/files/etc/init.d/done2
-rw-r--r--package/base-files/files/lib/preinit/80_mount_root2
2 files changed, 3 insertions, 1 deletions
diff --git a/package/base-files/files/etc/init.d/done b/package/base-files/files/etc/init.d/done
index 374353a23c..32d6118df7 100755
--- a/package/base-files/files/etc/init.d/done
+++ b/package/base-files/files/etc/init.d/done
@@ -4,7 +4,7 @@
START=95
boot() {
mount_root done
- rm -f /sysupgrade.tgz
+ rm -f /sysupgrade.tgz && sync
# process user commands
[ -f /etc/rc.local ] && {
diff --git a/package/base-files/files/lib/preinit/80_mount_root b/package/base-files/files/lib/preinit/80_mount_root
index f3fe788e19..265a3f18df 100644
--- a/package/base-files/files/lib/preinit/80_mount_root
+++ b/package/base-files/files/lib/preinit/80_mount_root
@@ -9,6 +9,8 @@ do_mount_root() {
echo "- config restore -"
cd /
tar xzf /sysupgrade.tgz
+ # Prevent configuration corruption on a power loss
+ sync
}
}