Blame SOURCES/0190-base-init.sh-use-loop-counter-with-unique-varname.patch

712866
From ef6665ec410fe89af700e3257942083f4ea629a8 Mon Sep 17 00:00:00 2001
712866
From: Harald Hoyer <harald@redhat.com>
712866
Date: Fri, 27 Jun 2014 18:05:37 +0200
712866
Subject: [PATCH] base/init.sh: use loop counter with unique varname
712866
712866
$i can be polluted too easily
712866
712866
(cherry picked from commit 6525182bfc06abfffd71dafc06c5faca6c55eace)
712866
---
712866
 modules.d/99base/init.sh | 6 +++---
712866
 1 file changed, 3 insertions(+), 3 deletions(-)
712866
712866
diff --git a/modules.d/99base/init.sh b/modules.d/99base/init.sh
5c6c2a
index 9ee3e9dc..dcc62d2a 100755
712866
--- a/modules.d/99base/init.sh
712866
+++ b/modules.d/99base/init.sh
712866
@@ -231,7 +231,7 @@ source_hook pre-mount
712866
 getarg 'rd.break=mount' -d 'rdbreak=mount' && emergency_shell -n mount "Break mount"
712866
 # mount scripts actually try to mount the root filesystem, and may
712866
 # be sourced any number of times. As soon as one suceeds, no more are sourced.
712866
-i=0
712866
+_i_mount=0
712866
 while :; do
712866
     if ismounted "$NEWROOT"; then
712866
         usable_root "$NEWROOT" && break;
712866
@@ -247,8 +247,8 @@ while :; do
712866
         fi
712866
     done
712866
 
712866
-    i=$(($i+1))
712866
-    [ $i -gt 20 ] \
712866
+    _i_mount=$(($_i_mount+1))
712866
+    [ $_i_mount -gt 20 ] \
712866
         && { flock -s 9 ; action_on_fail "Can't mount root filesystem" && break; } 9>/.console_lock
712866
 done
712866