From 81addc77b4e3ebff94e33537c409e7e8d6686e1b Mon Sep 17 00:00:00 2001 From: Alexis La Goutte Date: Sun, 4 Oct 2015 14:48:32 +0200 Subject: [PATCH] Add (and fix) -Wredundant-decls --- configure.ac | 1 + lib/nghttp2_hd_huffman.c | 3 --- tests/nghttp2_session_test.c | 2 -- 3 files changed, 1 insertion(+), 5 deletions(-) diff --git a/configure.ac b/configure.ac index cc677875..f0b2615f 100644 --- a/configure.ac +++ b/configure.ac @@ -655,6 +655,7 @@ if test "x$werror" != "xno"; then AX_CHECK_COMPILE_FLAG([-Wunreachable-code-break], [CFLAGS="$CFLAGS -Wunreachable-code-break"]) AX_CHECK_COMPILE_FLAG([-Wunused-macros], [CFLAGS="$CFLAGS -Wunused-macros"]) AX_CHECK_COMPILE_FLAG([-Wunused-parameter], [CFLAGS="$CFLAGS -Wunused-parameter"]) + AX_CHECK_COMPILE_FLAG([-Wredundant-decls], [CFLAGS="$CFLAGS -Wredundant-decls"]) # Only work with Clang for the moment AX_CHECK_COMPILE_FLAG([-Wheader-guard], [CFLAGS="$CFLAGS -Wheader-guard"]) fi diff --git a/lib/nghttp2_hd_huffman.c b/lib/nghttp2_hd_huffman.c index fb2d167b..7b1c4aba 100644 --- a/lib/nghttp2_hd_huffman.c +++ b/lib/nghttp2_hd_huffman.c @@ -30,9 +30,6 @@ #include "nghttp2_hd.h" -extern const nghttp2_huff_sym huff_sym_table[]; -extern const nghttp2_huff_decode huff_decode_table[][16]; - /* * Encodes huffman code |sym| into |*dest_ptr|, whose least |rembits| * bits are not filled yet. The |rembits| must be in range [1, 8], diff --git a/tests/nghttp2_session_test.c b/tests/nghttp2_session_test.c index aeb5f495..12f3e7dd 100644 --- a/tests/nghttp2_session_test.c +++ b/tests/nghttp2_session_test.c @@ -36,8 +36,6 @@ #include "nghttp2_test_helper.h" #include "nghttp2_priority_spec.h" -extern int nghttp2_enable_strict_preface; - #define OB_CTRL(ITEM) nghttp2_outbound_item_get_ctrl_frame(ITEM) #define OB_CTRL_TYPE(ITEM) nghttp2_outbound_item_get_ctrl_frame_type(ITEM) #define OB_DATA(ITEM) nghttp2_outbound_item_get_data_frame(ITEM)