From: W.C.A. Wijngaards Date: Thu, 15 Aug 2019 13:05:02 +0000 (+0200) Subject: - escape commandline contents for -V. X-Git-Tag: release-1.9.3rc1~2 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=06a58ca2484eedf97494c0b62f7debb8a0966ce2;p=thirdparty%2Funbound.git - escape commandline contents for -V. --- diff --git a/configure b/configure index 53d2705c7..30152828e 100755 --- a/configure +++ b/configure @@ -2889,8 +2889,10 @@ LIBUNBOUND_AGE=1 +cmdln="`echo $@ | sed -e 's/\\\\/\\\\\\\\/g' | sed -e 's/"/\\\\"/'g`" + cat >>confdefs.h <<_ACEOF -#define CONFCMDLINE "$@" +#define CONFCMDLINE "$cmdln" _ACEOF diff --git a/configure.ac b/configure.ac index 76ab6c1aa..18030728b 100644 --- a/configure.ac +++ b/configure.ac @@ -112,7 +112,9 @@ AC_SUBST(LIBUNBOUND_CURRENT) AC_SUBST(LIBUNBOUND_REVISION) AC_SUBST(LIBUNBOUND_AGE) -AC_DEFINE_UNQUOTED(CONFCMDLINE, "$@", [Command line arguments used with configure]) + +cmdln="`echo $@ | sed -e 's/\\\\/\\\\\\\\/g' | sed -e 's/"/\\\\"/'g`" +AC_DEFINE_UNQUOTED(CONFCMDLINE, ["$cmdln"], [Command line arguments used with configure]) CFLAGS="$CFLAGS" AC_AIX diff --git a/doc/Changelog b/doc/Changelog index 5a7221e63..786f3c3e6 100644 --- a/doc/Changelog +++ b/doc/Changelog @@ -2,6 +2,7 @@ - iana portlist updated. - Fix autotrust temp file uniqueness windows compile. - avoid warning about upcast on 32bit systems for autotrust. + - escape commandline contents for -V. 14 August 2019: George - Fix #59, when compiled with systemd support check that we can properly