summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarcel Raad <raad@teamviewer.com>2017-06-14 18:18:41 +0200
committerMarcel Raad <raad@teamviewer.com>2017-06-16 22:31:48 +0200
commit783ce023a54cde30f9b3597554d65e0d24aa2655 (patch)
tree211dd3acbdf612a18125b9f032ef311af1f4974c
parent01811b67405c54960c2175075691f59a0d066068 (diff)
downloadcurl-783ce023a54cde30f9b3597554d65e0d24aa2655.tar.gz
curl-compilers.m4: enable vla warning for clang
Previously, that warning was only implicitly active in C90 mode. Enable it unconditionally as already done for GCC. Closes https://github.com/curl/curl/pull/1578
-rw-r--r--m4/curl-compilers.m45
1 files changed, 5 insertions, 0 deletions
diff --git a/m4/curl-compilers.m4 b/m4/curl-compilers.m4
index 88e9d67ba..5860f946e 100644
--- a/m4/curl-compilers.m4
+++ b/m4/curl-compilers.m4
@@ -882,6 +882,11 @@ AC_DEFUN([CURL_SET_COMPILER_WARNING_OPTS], [
tmp_CFLAGS="$tmp_CFLAGS -Wunused"
fi
#
+ dnl Only clang 2.8 or later
+ if test "$compiler_num" -ge "208"; then
+ tmp_CFLAGS="$tmp_CFLAGS -Wvla"
+ fi
+ #
dnl Only clang 2.9 or later
if test "$compiler_num" -ge "209"; then
tmp_CFLAGS="$tmp_CFLAGS -Wshift-sign-overflow"