Add -Wused-but-marked-unused as an extra warning flag.

We can't just turn it on yet, because that would require generators to
know which generated functions use which parameters and mark only the
unused ones as such.  The generator that turns PIDL files into DCE RPC
dissectors is one that would have to be fixed.

Change-Id: I42013c8983d01fd3eca4026358b37ba043f12190
Reviewed-on: https://code.wireshark.org/review/23246
Reviewed-by: Guy Harris <guy@alum.mit.edu>
This commit is contained in:
Guy Harris 2017-08-27 13:55:14 -07:00
parent ef3b7a3394
commit d846a3e8b9
1 changed files with 7 additions and 0 deletions

View File

@ -755,6 +755,13 @@ AC_ARG_ENABLE(extra-compiler-warnings,
# never enable this one with -Werror.
#
AC_WIRESHARK_COMPILER_FLAGS_CHECK(-Wbad-function-cast, C)
#
# This causes some generated files to fail with -Werror;
# fixing that would require the generator to figure
# out in which functions use which parameters.
#
AC_WIRESHARK_COMPILER_FLAGS_CHECK(-Wused-but-marked-unused, C)
fi
])