Przeglądaj źródła

mklive: check if pseudofs exists before umounting it

classabbyamp 1 rok temu
rodzic
commit
9708d22136
1 zmienionych plików z 1 dodań i 1 usunięć
  1. 1 1
      mklive.sh

+ 1 - 1
mklive.sh

@@ -52,7 +52,7 @@ mount_pseudofs() {
 }
 umount_pseudofs() {
 	for f in sys dev proc; do
-		if ! umount -R -f "$ROOTFS/$f"; then
+		if [ -d "$ROOTFS/$f" ] && ! umount -R -f "$ROOTFS/$f"; then
 			info_msg "ERROR: failed to unmount $ROOTFS/$f/"
 			return 1
 		fi