From: Mark Andrews Date: Fri, 9 Aug 2019 03:02:07 +0000 (+1000) Subject: don't escape commas when saving named's command line X-Git-Tag: v9.15.4~20^2~1 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=70dd93bf8a3512b7ae98f7990e9e8b35fe0adb14;p=thirdparty%2Fbind9.git don't escape commas when saving named's command line --- diff --git a/bin/named/main.c b/bin/named/main.c index 7c1c13933b9..09842fd4729 100644 --- a/bin/named/main.c +++ b/bin/named/main.c @@ -352,7 +352,7 @@ save_command_line(int argc, char *argv[]) { *dst++ = ' '; while (*src != '\0' && dst < eob) { - if (isalnum(*src) || + if (isalnum(*src) || *src == ',' || *src == '-' || *src == '_' || *src == '.' || *src == '/') { diff --git a/bin/tests/system/resolver/tests.sh b/bin/tests/system/resolver/tests.sh index 6706e65675c..d777ea1ab5d 100755 --- a/bin/tests/system/resolver/tests.sh +++ b/bin/tests/system/resolver/tests.sh @@ -795,5 +795,12 @@ grep "status: SERVFAIL" dig.ns5.out.${n} > /dev/null || ret=1 if [ $ret != 0 ]; then echo_i "failed"; fi status=`expr $status + $ret` +n=`expr $n + 1` +echo_i "check logged command line ($n)" +ret=0 +grep "running as: .* -m record,size,mctx " ns1/named.run > /dev/null || ret=1 +if [ $ret != 0 ]; then echo_i "failed"; fi +status=`expr $status + $ret` + echo_i "exit status: $status" [ $status -eq 0 ] || exit 1