28 November 2018: Wouter
- Fix leak in chroot fix for auth-zone.
+ - Fix clang analysis for outside directory build test.
27 November 2018: Wouter
- Fix DNS64 to not store intermediate results in cache, this avoids
if test "$WITH_PYTHONMODULE" = "yes"; then PYTHONMOD_SRC="pythonmod/*.c"; fi
if test ! -z "$WINAPPS"; then WIN_SRC="winrc/*.c"; fi
-cd $PRE; cd $srcdir
+cd $PRE;
+odir=`pwd`
+cd $srcdir
# check the files in the srcdir
fail="no"
for x in cachedb/*.c daemon/*.c dns64/*.c $DNSCRYPT_SRC $DNSTAP_SRC edns-subnet/*.c ipsecmod/*.c iterator/*.c libunbound/*.c $PYTHONMOD_SRC respip/*.c services/*.c services/*/*.c sldns/*.c smallapp/*.c util/*.c util/*/*.c validator/*.c $WIN_SRC $compatfiles testcode/*.c; do
echo clang --analyze $CPPFLAGS $x
plist=`basename $x .c`.plist
rm -rf $plist
- clang --analyze $CPPFLAGS $x 2>&1 | tee tmp.$$
+ #echo "(cd $odir; clang --analyze $CPPFLAGS $srcdir/$x 2>&1 ) | tee tmp.$$"
+ (cd "$odir"; clang --analyze $CPPFLAGS $srcdir/$x 2>&1 ) | tee tmp.$$
if grep -e warning -e error tmp.$$ >/dev/null; then
fail="yes"
fails="$fails $x"