Ver Fonte

mklive: check if pseudofs exists before umounting it

classabbyamp há 1 ano atrás
pai
commit
9708d22136
1 ficheiros alterados com 1 adições e 1 exclusões
  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