diff options
Diffstat (limited to 'epan/dissectors/packet-dvmrp.c')
-rw-r--r-- | epan/dissectors/packet-dvmrp.c | 16 |
1 files changed, 14 insertions, 2 deletions
diff --git a/epan/dissectors/packet-dvmrp.c b/epan/dissectors/packet-dvmrp.c index fead40077f..54a85eb372 100644 --- a/epan/dissectors/packet-dvmrp.c +++ b/epan/dissectors/packet-dvmrp.c @@ -53,6 +53,7 @@ #include <epan/packet.h> #include <epan/prefs.h> +#include <epan/expert.h> #include "packet-igmp.h" void proto_register_dvmrp(void); @@ -109,6 +110,8 @@ static int ett_capabilities = -1; static int ett_flags = -1; static int ett_route = -1; +static expert_field ei_checksum = EI_INIT; + static int strict_v3 = FALSE; #define DVMRP_TYPE 0x13 @@ -336,7 +339,7 @@ dissect_dvmrp_v3(tvbuff_t *tvb, packet_info *pinfo, proto_tree *parent_tree, int "Unknown Type:0x%02x")); /* checksum */ - igmp_checksum(parent_tree, tvb, hf_checksum, hf_checksum_status, pinfo, 0); + igmp_checksum(parent_tree, tvb, hf_checksum, hf_checksum_status, &ei_checksum, pinfo, 0); offset += 2; /* skip unused byte */ @@ -525,7 +528,7 @@ dissect_dvmrp_v1(tvbuff_t *tvb, packet_info *pinfo, proto_tree *parent_tree, int "Unknown Type:0x%02x")); /* checksum */ - igmp_checksum(parent_tree, tvb, hf_checksum, hf_checksum_status, pinfo, 0); + igmp_checksum(parent_tree, tvb, hf_checksum, hf_checksum_status, &ei_checksum, pinfo, 0); offset += 2; /* decode all the v1 commands */ @@ -883,11 +886,20 @@ proto_register_dvmrp(void) &ett_flags, &ett_route }; + + static ei_register_info ei[] = { + { &ei_checksum, { "dvmrp.bad_checksum", PI_CHECKSUM, PI_ERROR, "Bad checksum", EXPFILL }}, + }; + + expert_module_t* expert_dvmrp; + module_t *module_dvmrp; proto_dvmrp = proto_register_protocol("Distance Vector Multicast Routing Protocol", "DVMRP", "dvmrp"); proto_register_field_array(proto_dvmrp, hf, array_length(hf)); proto_register_subtree_array(ett, array_length(ett)); + expert_dvmrp = expert_register_protocol(proto_dvmrp); + expert_register_field_array(expert_dvmrp, ei, array_length(ei)); module_dvmrp = prefs_register_protocol(proto_dvmrp, NULL); |