diff options
author | nbd <nbd@3c298f89-4303-0410-b956-a3cf2f4a3e73> | 2006-11-09 02:02:13 +0000 |
---|---|---|
committer | nbd <nbd@3c298f89-4303-0410-b956-a3cf2f4a3e73> | 2006-11-09 02:02:13 +0000 |
commit | e3eab11e630a2119b09c8daebe9d8038a03d178b (patch) | |
tree | 117a712b1c32dd3e8d399f7116970487ef9a684c /package/base-files/default | |
parent | 94d065bb1e4b8a8a6c1322ae57060b84608991e0 (diff) |
fix potential data loss issue on failed umount (patch from #942)
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@5474 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'package/base-files/default')
-rwxr-xr-x | package/base-files/default/etc/hotplug.d/block/01-mount | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/package/base-files/default/etc/hotplug.d/block/01-mount b/package/base-files/default/etc/hotplug.d/block/01-mount index b6275e5a2..db8ccdabd 100755 --- a/package/base-files/default/etc/hotplug.d/block/01-mount +++ b/package/base-files/default/etc/hotplug.d/block/01-mount @@ -19,8 +19,8 @@ add) } ;; remove) - umount /tmp/$DEV - rm -rf /dev/$DEV /tmp/$DEV + umount /tmp/$DEV && rmdir /tmp/$DEV + rm -f /dev/$DEV /tmp/$DEV ;; esac } 2>&1 | logger |