aboutsummaryrefslogtreecommitdiffstats
path: root/epan/dissectors/packet-newmail.c
diff options
context:
space:
mode:
authormorriss <morriss@f5534014-38df-0310-8fa8-9805f1628bb7>2012-06-20 13:30:07 +0000
committermorriss <morriss@f5534014-38df-0310-8fa8-9805f1628bb7>2012-06-20 13:30:07 +0000
commitc8391561bf16bde475344593e7987bc45c94944e (patch)
tree7f1ac290c1925812ef8d63c739a0e558ed2cd958 /epan/dissectors/packet-newmail.c
parentade3bd548ae4b02c8cb9bb8344b9329997ed62d8 (diff)
Use separate filters for the RTT found on a SACK and the RTT found on a
DATA chunk: having them in both places is helpful when looking at the messages but having them separate is helpful when graphing the RTTs. git-svn-id: http://anonsvn.wireshark.org/wireshark/trunk@43406 f5534014-38df-0310-8fa8-9805f1628bb7
Diffstat (limited to 'epan/dissectors/packet-newmail.c')
-rw-r--r--epan/dissectors/packet-newmail.c29
1 files changed, 9 insertions, 20 deletions
diff --git a/epan/dissectors/packet-newmail.c b/epan/dissectors/packet-newmail.c
index 9e795b694e..7f8e92216b 100644
--- a/epan/dissectors/packet-newmail.c
+++ b/epan/dissectors/packet-newmail.c
@@ -8,12 +8,6 @@
* By Gerald Combs <gerald@wireshark.org>
* Copyright 1998 Gerald Combs
*
- * Copied from WHATEVER_FILE_YOU_USED (where "WHATEVER_FILE_YOU_USED"
- * is a dissector file; if you just copied this from README.developer,
- * don't bother with the "Copied from" - you don't even need to put
- * in a "Copied from" if you copied an existing dissector, especially
- * if the bulk of the code in the new dissector is your code)
- *
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License
* as published by the Free Software Foundation; either version 2
@@ -33,14 +27,11 @@
# include "config.h"
#endif
-#include <stdlib.h>
-
#include <glib.h>
#include <epan/packet.h>
#include <epan/prefs.h>
-/* Forward declaration we need below */
void proto_reg_handoff_newmail(void);
/* Variables for preferences */
@@ -97,25 +88,23 @@ proto_register_newmail(void)
module_t *newmail_module;
- /* Register the protocol name and description */
proto_newmail = proto_register_protocol("Microsoft Exchange New Mail Notification",
"NEWMAIL", "newmail");
- /* Required function calls to register the header fields and subtrees used */
proto_register_field_array(proto_newmail, hf, array_length(hf));
proto_register_subtree_array(ett, array_length(ett));
- /* Register the dissector without a port yet */
register_dissector("newmail", dissect_newmail, proto_newmail);
- /* Register preferences module */
newmail_module = prefs_register_protocol(proto_newmail,
proto_reg_handoff_newmail);
prefs_register_uint_preference(newmail_module,
"default_port",
"Default UDP port (optional)",
- "Always dissect this port's traffic as newmail notifications. Additional ports will be dynamically registered as they are seen in MAPI register push notification packets.",
+ "Always dissect this port's traffic as newmail notifications."
+ " Additional ports will be dynamically registered as they"
+ " are seen in MAPI register push notification packets.",
10, &preference_default_port);
}
@@ -125,20 +114,20 @@ proto_reg_handoff_newmail(void)
{
static gboolean inited = FALSE;
static dissector_handle_t newmail_handle;
- static guint preference_default_port_last;
+ static guint preference_default_port_last;
if(!inited) {
newmail_handle = find_dissector("newmail");
dissector_add_handle("udp.port", newmail_handle); /* for 'decode-as' */
inited = TRUE;
} else {
- if (preference_default_port_last != 0) {
- dissector_delete_uint("udp.port", preference_default_port_last, newmail_handle);
- }
- }
+ if (preference_default_port_last != 0) {
+ dissector_delete_uint("udp.port", preference_default_port_last, newmail_handle);
+ }
+ }
if(preference_default_port != 0) {
dissector_add_uint("udp.port", preference_default_port, newmail_handle);
}
- preference_default_port_last = preference_default_port;
+ preference_default_port_last = preference_default_port;
}