dracut-systemd/rootfs-generator.sh: use strstr rather than grep

grep on /proc/cmdline is overkill and would add a requirement for grep
master
Harald Hoyer 2015-04-21 16:35:34 +02:00
parent 23446ef1e0
commit d3d52b20e9
1 changed files with 1 additions and 1 deletions

View File

@ -92,7 +92,7 @@ esac

if [ "${root%%:*}" = "block" ]; then
generator_wait_for_dev "${root#block:}" "$RDRETRY"
grep -q 'root=' /proc/cmdline || generator_mount_rootfs "${root#block:}" "$(getarg rootfstype=)" "$(getarg rootflags=)"
strstr "$(cat /proc/cmdline)" 'root=' || generator_mount_rootfs "${root#block:}" "$(getarg rootfstype=)" "$(getarg rootflags=)"
fi

exit 0