configure.ac: Add -Wpointer-arith to the maintainer CFLAGS
GCC by default allows pointer arithmetic on void* pointers and treats them as having a size of 1 byte. This is non-standard behaviour and causes errors on some compilers so we should try to avoid it. -Wpointer-arith warns about these cases.
This commit is contained in:
parent
6dc4af1c5d
commit
e52cc75f07
@ -1096,7 +1096,8 @@ AC_ARG_ENABLE([maintainer-flags],
|
||||
MAINTAINER_COMPILER_FLAGS="-Wall -Wshadow -Wcast-align -Wuninitialized
|
||||
-Wno-strict-aliasing -Wempty-body -Wformat
|
||||
-Wformat-security -Winit-self
|
||||
-Wdeclaration-after-statement -Wvla"
|
||||
-Wdeclaration-after-statement -Wvla
|
||||
-Wpointer-arith"
|
||||
|
||||
AS_CASE([$enable_maintainer_flags],
|
||||
[yes],
|
||||
|
Loading…
Reference in New Issue
Block a user