From 10a128ac7b48669dbe96db4efcc2addf6d43c8d1 Mon Sep 17 00:00:00 2001 From: ivo Date: Mon, 7 May 2007 17:17:10 +0000 Subject: do not run stupid code checks if chfilelist is empty (i.e. it is run on non-c code only) git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@23251 b3059339-0415-0410-9bf9-f77b7e298cf2 --- TOOLS/checktree.sh | 2 ++ 1 file changed, 2 insertions(+) (limited to 'TOOLS') diff --git a/TOOLS/checktree.sh b/TOOLS/checktree.sh index 2e61659612..d03232bcd7 100755 --- a/TOOLS/checktree.sh +++ b/TOOLS/checktree.sh @@ -303,6 +303,7 @@ if [ "$_stupid" = "yes" ]; then # avoid false-positives in xpm files, docs, etc, only check .c and .h files chfilelist=`echo $filelist | tr ' ' '\n' | grep "[\.][ch]$"` + if [ -n "$chfilelist" ]; then for i in calloc malloc realloc memalign av_malloc av_mallocz faad_malloc \ lzo_malloc safe_malloc mpeg2_malloc _ogg_malloc; do printhead "--> casting of void* $i()" @@ -337,6 +338,7 @@ if [ "$_stupid" = "yes" ]; then printhead "--> usage of -0" grep $_grepopts "[a-zA-Z0-9)]\+[ ]*-[ ]*0[^.0-9xa-fA-F_]" $chfilelist + fi fi # ----------------------------------------------------------------------------- -- cgit v1.2.3