summaryrefslogtreecommitdiff
path: root/tools/mpfrlint
diff options
context:
space:
mode:
authorvlefevre <vlefevre@280ebfd0-de03-0410-8827-d642c229c3f4>2011-01-21 14:19:35 +0000
committervlefevre <vlefevre@280ebfd0-de03-0410-8827-d642c229c3f4>2011-01-21 14:19:35 +0000
commit9b77dbf68766fdc411ac9658e8b1c812cf1c383a (patch)
treef0fab57d6177da7dacff440e3d28dcfaf3ade892 /tools/mpfrlint
parent5bebb96a811216f4ea95e3ba3de2d3c94e9fa066 (diff)
downloadmpfr-9b77dbf68766fdc411ac9658e8b1c812cf1c383a.tar.gz
[tools/mpfrlint] Update the check for mpfr_printf-like functions
in the tests. git-svn-id: svn://scm.gforge.inria.fr/svn/mpfr/trunk@7413 280ebfd0-de03-0410-8827-d642c229c3f4
Diffstat (limited to 'tools/mpfrlint')
-rwxr-xr-xtools/mpfrlint10
1 files changed, 4 insertions, 6 deletions
diff --git a/tools/mpfrlint b/tools/mpfrlint
index 4e594d26e..eed89318c 100755
--- a/tools/mpfrlint
+++ b/tools/mpfrlint
@@ -62,12 +62,10 @@ done
# as they need <stdarg.h> (HAVE_STDARG defined).
for file in tests/*.c
do
- case $file in
- *printf*) ;;
- tests/tvalist.c) ;;
- *) grep -q "mpfr_[a-z]*printf" $file && \
- echo "$file contains mpfr_printf-like function calls" ;;
- esac
+ sed '/#if\(def\)\? *HAVE_STDARG/,/#\(endif\|else\) .*HAVE_STDARG/d
+ /\/\*.*\*\//d
+ /\/\*/,/\*\//d' $file | grep -q "mpfr_[a-z]*printf" && \
+ echo "$file contains unprotected mpfr_printf-like function calls"
done
fdlv1="`sed -n '/Version / {