]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
tests: osd-scrub-snaps.sh minor cleanup
authorDavid Zafman <dzafman@redhat.com>
Tue, 15 Aug 2017 21:46:40 +0000 (14:46 -0700)
committerDavid Zafman <dzafman@redhat.com>
Tue, 22 Aug 2017 00:08:14 +0000 (17:08 -0700)
Signed-off-by: David Zafman <dzafman@redhat.com>
qa/standalone/scrub/osd-scrub-snaps.sh

index 8fa348ec6b7dbcd10f1512bb3a02fd9f5a7661a3..4c03bdb9efcd1cfd737e20b2ff210f68f87cf000 100755 (executable)
@@ -453,11 +453,11 @@ EOF
     err_strings[22]="log_channel[(]cluster[)] log [[]ERR[]] : [0-9]*[.]0 scrub 22 errors"
     err_strings[23]="log_channel[(]cluster[)] log [[]ERR[]] : scrub [0-9]*[.]0 .*:::obj15:head can't decode 'snapset' attr buffer"
 
-    for i in `seq 0 ${#err_strings[@]}`
+    for err_string in "${err_strings[@]}"
     do
-        if ! grep "${err_strings[$i]}" $dir/osd.0.log > /dev/null;
+        if ! grep "$err_string" $dir/osd.0.log > /dev/null;
         then
-            echo "Missing log message '${err_strings[$i]}'"
+            echo "Missing log message '$err_string'"
             ERRORS=$(expr $ERRORS + 1)
         fi
     done