aboutsummaryrefslogtreecommitdiffstats
path: root/epan/dissectors/packet-netflow.c
diff options
context:
space:
mode:
authorBill Meier <wmeier@newsguy.com>2008-09-22 16:26:41 +0000
committerBill Meier <wmeier@newsguy.com>2008-09-22 16:26:41 +0000
commit6aa5f8aa6af33baa7b2f37e14cbfc3e73136b333 (patch)
tree809bb5319c74d76eab725742a75769e9e890a76a /epan/dissectors/packet-netflow.c
parentc08a1f420e484941db43234a2236c57df6a9ef45 (diff)
Minor cleanup related to proto_reg_handoff
svn path=/trunk/; revision=26246
Diffstat (limited to 'epan/dissectors/packet-netflow.c')
-rw-r--r--epan/dissectors/packet-netflow.c25
1 files changed, 14 insertions, 11 deletions
diff --git a/epan/dissectors/packet-netflow.c b/epan/dissectors/packet-netflow.c
index 596fed6e5c..7dd358a728 100644
--- a/epan/dissectors/packet-netflow.c
+++ b/epan/dissectors/packet-netflow.c
@@ -85,19 +85,9 @@ static dissector_handle_t netflow_handle;
*/
static range_t *global_netflow_ports = NULL;
/*
- * netflow_ports : holds the currently used range of ports for netflow
- */
-static range_t *netflow_ports = NULL;
-
-/*
* global_ipfix_ports : holds the configured range of ports for IPFIX
*/
static range_t *global_ipfix_ports = NULL;
-/*
- * ipfix_ports : holds the currently used range of ports for IPFIX
- */
-static range_t *ipfix_ports = NULL;
-
/*
* pdu identifiers & sizes
@@ -3176,6 +3166,19 @@ ipfix_add_callback(guint32 port)
static void
netflow_reinit(void)
{
+ /* XXX: registered as an "init" routine and also called whenever a netflow pref */
+ /* is changed. The result thus appears to be that netflow_reinit is called */
+ /* twice whenever a netflow pref is changed. */
+
+ /*
+ * netflow_ports : holds the currently used range of ports for netflow
+ */
+ static range_t *netflow_ports = NULL;
+ /*
+ * ipfix_ports : holds the currently used range of ports for IPFIX
+ */
+ static range_t *ipfix_ports = NULL;
+
int i;
/*
@@ -4326,7 +4329,7 @@ proto_register_netflow(void)
void
proto_reg_handoff_netflow(void)
{
- static int netflow_prefs_initialized = FALSE;
+ static gboolean netflow_prefs_initialized = FALSE;
if (!netflow_prefs_initialized) {
netflow_handle = new_create_dissector_handle(dissect_netflow,