]> git.ipfire.org Git - thirdparty/dracut.git/commitdiff
fix IFS restoring
authorHarald Hoyer <harald@redhat.com>
Thu, 18 Feb 2010 08:46:19 +0000 (09:46 +0100)
committerHarald Hoyer <harald@redhat.com>
Thu, 18 Feb 2010 08:46:19 +0000 (09:46 +0100)
modules.d/95iscsi/iscsiroot
modules.d/95nfs/nfsroot
modules.d/95rootfs-block/mount-root.sh
modules.d/99base/dracut-lib.sh

index 308faa488fdc18bb695fc7d9de586d640ed21a92..6d0dde67abd5a218bdacb565755420f511a5d0b5 100755 (executable)
@@ -112,7 +112,7 @@ iscsi_target_port=$1; shift
 iscsi_lun=$1; shift
 IFS=:
 iscsi_target_name=$*
-IFS=$OLDIFS
+IFS="$OLDIFS"
 # XXX is this needed?
 getarg ro && iscsirw=ro
 getarg rw && iscsirw=rw
index fb7d5f48ab43e6f84abd8eae48da6103c4d48b0b..6ae4e0be68af8f8f5d048a952a65b99a6fb57b16 100755 (executable)
@@ -63,14 +63,14 @@ if [ "${path#*%s}" != "$path" ]; then
 fi
 
 # Look through the options and remove rw/locking options
-OLDIFS=$IFS
+OLDIFS="$IFS"
 IFS=,
 for f in $options ; do
     [ "$f" = "ro" -o "$f" = "rw" ] && nfsrw=$f && continue
     [ "$f" = "lock" -o "$f" = "nolock" ] && nfslock=$f && continue
     flags=${flags:+$flags,}$f
 done
-IFS=$OLDIFS
+IFS="$OLDIFS"
 options=$flags
 
 # Override rw/ro if set on cmdline
index 3c18406c1a58876811a85f6805c3790e9e558307..2b4c78560ec9252c6b5ea203a9364113413dd0d7 100755 (executable)
@@ -5,10 +5,10 @@
 filter_rootopts() {
     rootopts=$1
     # strip ro and rw options
-    local OLDIFS=$IFS
+    local OLDIFS="$IFS"
     IFS=,
     set -- $rootopts
-    IFS=$OLDIFS
+    IFS="$OLDIFS"
     local v
     while [ $# -gt 0 ]; do
         case $1 in
index 100219e6e211db9de8b3244ab6f2f42304a3f55e..de235666af8ab5aa38299a8d19aee35709ac0caa 100644 (file)
@@ -48,7 +48,7 @@ setdebug() {
     if [ -z "$RDDEBUG" ]; then
         if [ -e /proc/cmdline ]; then
             RDDEBUG=no
-           if getarg rdinitdebug; then
+            if getarg rdinitdebug; then
                 RDDEBUG=yes 
             fi
         fi
@@ -186,8 +186,6 @@ nfsroot_to_var() {
     local arg="$@:"
     nfs="${arg%%:*}"
     arg="${arg##$nfs:}"
-    # check for server
-    local OLDIFS="$IFS"
 
     # check if we have a server
     if strstr "$arg" ':/*' ; then