]> git.ipfire.org Git - thirdparty/dracut.git/commitdiff
base/dracut-lib.sh:ismounted() check for block device rather than pathname
authorHarald Hoyer <harald@redhat.com>
Tue, 31 Jul 2012 12:44:50 +0000 (14:44 +0200)
committerHarald Hoyer <harald@redhat.com>
Tue, 31 Jul 2012 12:44:50 +0000 (14:44 +0200)
modules.d/99base/dracut-lib.sh

index a39ca8c5d7c70ded1070c3ce0ccd7933025c8316..7ea5c5441363fcad21af5a26f5c1295e2d42e2eb 100755 (executable)
@@ -464,7 +464,7 @@ find_mount() {
 # usage: ismounted <mountpoint>
 # usage: ismounted /dev/<device>
 ismounted() {
-    if str_starts "$1" "/dev/"; then
+    if [ -b "$1" ]; then
         find_mount "$1" > /dev/null && return 0
         return 1
     fi