From 825af858a175e7a7ca41735ac0e6223306423250 Mon Sep 17 00:00:00 2001 From: vapier Date: Sun, 16 Apr 2006 21:14:59 +0000 Subject: add a check for obsolete headers git-svn-id: svn://busybox.net/trunk/busybox@14893 69ca8d6d-28ef-0310-b511-8ec308f3f277 --- testsuite/all_sourcecode.tests | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) diff --git a/testsuite/all_sourcecode.tests b/testsuite/all_sourcecode.tests index 23b8aec88..83b4bd507 100755 --- a/testsuite/all_sourcecode.tests +++ b/testsuite/all_sourcecode.tests @@ -56,9 +56,19 @@ rm -f src.typos # find $srcdir/.. '(' -name '*.c' -o -name '*.h' ')' -print0 | xargs -0 \ grep -E -e '\<(bcmp|bcopy|bzero|getwd|index|mktemp|rindex|utimes)\>[[:space:]]*\(' \ - | sed -e "s:^$srcdir/\.\./::g" > src.obsolete -testing "Obsolete function usage" "cat src.obsolete" "" "" "" -rm -f src.obsolete + | sed -e "s:^$srcdir/\.\./::g" > src.obsolete.funcs +testing "Obsolete function usage" "cat src.obsolete.funcs" "" "" "" +rm -f src.obsolete.funcs + + +# +# don't allow obsolete headers +# +find $srcdir/.. '(' -name '*.c' -o -name '*.h' ')' -print0 | xargs -0 \ + grep -E -e '\<(malloc|memory)\.h\>' \ + | sed -e "s:^$srcdir/\.\./::g" > src.obsolete.headers +testing "Obsolete function usage" "cat src.obsolete.headers" "" "" "" +rm -f src.obsolete.headers exit $FAILCOUNT -- cgit v1.2.3-55-g6feb