From 0c39f5d219dfaae7a70e0715bde6bd41c3d2900e Mon Sep 17 00:00:00 2001 From: Jason Volk Date: Sat, 16 Feb 2019 12:33:30 -0800 Subject: [PATCH] configure: Treat -Wreturn-type as an error. --- configure.ac | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/configure.ac b/configure.ac index e324dd045..b2978052e 100644 --- a/configure.ac +++ b/configure.ac @@ -523,6 +523,14 @@ CHARYBDIS_C_GCC_TRY_FLAGS([-Wplacement-new=2], charybdis_cv_c_gcc_w_placement_ne CHARYBDIS_C_GCC_TRY_FLAGS([-Wundef], charybdis_cv_c_gcc_w_undef) CHARYBDIS_C_GCC_TRY_FLAGS([-Wodr], charybdis_cv_c_gcc_w_odr) +dnl +dnl List of warnings treated as errors +dnl + +dnl Uninitialized return values are not useful in this project; forgetting +dnl to return from a function is always a developer mistake here. +CHARYBDIS_C_GCC_TRY_FLAGS([-Werror=return-type], charybdis_cv_c_gcc_w_error_return_type) + dnl dnl List of warnings we suppress: dnl