Fixing possible invalid results from function where_is_mounted by returning more...
authorLuigi Capriotti <l.capriotti@xbmc.org>
Fri, 19 Jun 2009 13:07:40 +0000 (15:07 +0200)
committerDaniel Baumann <daniel@debian.org>
Fri, 19 Jun 2009 13:07:40 +0000 (15:07 +0200)
scripts/live-helpers

index 79b158c..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
 }