]> git.ipfire.org Git - thirdparty/bind9.git/commitdiff
b/t/s/dnssec/tests.sh: Cleanup showprivate() function
authorEvan Hunt <each@isc.org>
Mon, 14 Jan 2019 20:24:21 +0000 (12:24 -0800)
committerEvan Hunt <each@isc.org>
Mon, 14 Jan 2019 20:30:49 +0000 (12:30 -0800)
bin/tests/system/dnssec/tests.sh

index 65607392b92a4c4be9271d5e7746da560354db3c..7878a6c350e9412a28a7922b73b23244fdb30316 100644 (file)
@@ -40,18 +40,14 @@ showprivate () {
 }
 
 # check that signing records are marked as complete
-checkprivate () { (
+checkprivate () {
     for i in 1 2 3 4 5 6 7 8 9 10; do
-        ret=0
-        showprivate "$@" | grep incomplete >/dev/null 2>&1 && { ret=1; sleep 1; continue; }
-        break
+        showprivate "$@" | grep -q incomplete || return 0
+       sleep 1
     done
-    [ $ret -eq 1 ] && {
-        echo_d "$1 signing incomplete"
-        return 1
-    }
-    return 0
-) }
+    echo_d "$1 signing incomplete"
+    return 1
+}
 
 # check that a zone file is raw format, version 0
 israw0 () {