From: Will Woods Date: Thu, 13 Oct 2011 02:48:08 +0000 (-0400) Subject: dracut-lib.sh: fix dropped backslashes in CMDLINE X-Git-Tag: 014~59 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=2cd4a8065ac2bb6bf3708d681de56bbe1984c3ce;p=thirdparty%2Fdracut.git dracut-lib.sh: fix dropped backslashes in CMDLINE The "read" shell builtin consumes backslashes, which is a problem if your root device is something like "LABEL=Fedora\x2016". Using "read -r" tells the shell to leave backslashes alone. --- diff --git a/modules.d/99base/dracut-lib.sh b/modules.d/99base/dracut-lib.sh index 62c3bf54a..bc4d7c938 100755 --- a/modules.d/99base/dracut-lib.sh +++ b/modules.d/99base/dracut-lib.sh @@ -35,11 +35,11 @@ _getcmdline() { unset _line if [ -z "$CMDLINE" ]; then if [ -e /etc/cmdline ]; then - while read _line; do + while read -r _line; do CMDLINE_ETC="$CMDLINE_ETC $_line"; done