diff options
author | João Valverde <joao.valverde@tecnico.ulisboa.pt> | 2015-12-13 23:18:36 +0000 |
---|---|---|
committer | Guy Harris <guy@alum.mit.edu> | 2016-01-03 01:40:53 +0000 |
commit | 582e9579e0f86fe9f1487be77b8ba9ca19087dc8 (patch) | |
tree | ea180c3b8935669e6ce9a93fc71f51d114cdd2e4 | |
parent | 4473c676464805faf474a50fc076457ccf826234 (diff) |
proto.c: Disable warning when loading a symbol [-Wpedantic]
Change-Id: I309764e9cd0784c674a3cd91050eb697404561c6
Reviewed-on: https://code.wireshark.org/review/13012
Reviewed-by: Guy Harris <guy@alum.mit.edu>
-rw-r--r-- | epan/proto.c | 16 |
1 files changed, 12 insertions, 4 deletions
diff --git a/epan/proto.c b/epan/proto.c index bdb02be6d8..87088d89ce 100644 --- a/epan/proto.c +++ b/epan/proto.c @@ -397,18 +397,26 @@ check_for_dissector_plugin(GModule *handle) /* * Do we have a register routine? */ - if (g_module_symbol(handle, "plugin_register", &gp)) + if (g_module_symbol(handle, "plugin_register", &gp)) { +DIAG_OFF(pedantic) register_protoinfo = (void (*)(void))gp; - else +DIAG_ON(pedantic) + } + else { register_protoinfo = NULL; + } /* * Do we have a reg_handoff routine? */ - if (g_module_symbol(handle, "plugin_reg_handoff", &gp)) + if (g_module_symbol(handle, "plugin_reg_handoff", &gp)) { +DIAG_OFF(pedantic) reg_handoff = (void (*)(void))gp; - else +DIAG_ON(pedantic) + } + else { reg_handoff = NULL; + } /* * If we have neither, we're not a dissector plugin. |