From 451484b8703d7bd34dea2a52a90b8f1dfa4cc1bd Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20K=C4=99pie=C5=84?= Date: Thu, 16 Jan 2020 09:48:01 +0100 Subject: [PATCH] Fix the "dnssec" system test on Windows Make sure carriage return characters are stripped from awk input to enable the "dnssec" system test to pass on Windows. --- bin/tests/system/dnssec/tests.sh | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/bin/tests/system/dnssec/tests.sh b/bin/tests/system/dnssec/tests.sh index f46e68e591..66d4a39a08 100644 --- a/bin/tests/system/dnssec/tests.sh +++ b/bin/tests/system/dnssec/tests.sh @@ -108,11 +108,12 @@ stripns () { # Ensure there is not a blank line before "Secure roots:". # check_secroots_layout () { + tr -d '\r' < "$1" | \ awk '$0 == "" { if (empty) exit(1); empty=1; next } /Start view/ { if (!empty) exit(1) } /Secure roots:/ { if (empty) exit(1) } /Negative trust anchors:/ { if (!empty) exit(1) } - { empty=0 }' $1 + { empty=0 }' return $? }