Fixing typo in snapshot file list.
[live-boot-grml.git] / scripts / live-helpers
index c4fca95..fbf61fe 100644 (file)
@@ -104,7 +104,7 @@ where_is_mounted ()
        if grep -q "^${device} " /proc/mounts
        then
                # return the first found
-               grep "^${device} " /proc/mounts | cut -f2 -d ' '
+               grep -m1 "^${device} " /proc/mounts | cut -f2 -d ' '
        fi
 }
 
@@ -367,7 +367,7 @@ find_cow_device ()
                        if [ "$(/lib/udev/vol_id -l ${devname} 2>/dev/null)" = "${pers_label}" ]
                        then
                                echo "${devname}"
-                               return
+                               return 0
                        fi
 
                        if [ "${PERSISTENT}" = "nofiles" ]
@@ -398,6 +398,7 @@ find_cow_device ()
                        esac
                done
        done
+       return 1
 }
 
 find_files ()