summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlexis La Goutte <alexis.lagoutte@gmail.com>2016-05-22 18:33:21 +0200
committerMichael Mann <mmann78@netscape.net>2016-05-24 14:15:06 +0000
commitb565320aadabd9d976cd7e2fd789cbb847e49e38 (patch)
treec546a4f1d64f3eee98355b883978de560f1c47e7
parentce0223d410bc343258de0ad8575f66138bb85e00 (diff)
downloadwireshark-b565320aadabd9d976cd7e2fd789cbb847e49e38.tar.gz
OPA MAD: fix Result of operation is garbage or undefined found by Clang Analyzer
Change-Id: I16a81cacef2b576f634a6726fa1620a0e6660e76 Reviewed-on: https://code.wireshark.org/review/15533 Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Adam Goldman <adam.goldman@intel.com> Reviewed-by: Michael Mann <mmann78@netscape.net>
-rw-r--r--epan/dissectors/packet-opa-mad.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/epan/dissectors/packet-opa-mad.c b/epan/dissectors/packet-opa-mad.c
index 51818a253a..0eba9b0917 100644
--- a/epan/dissectors/packet-opa-mad.c
+++ b/epan/dissectors/packet-opa-mad.c
@@ -2847,6 +2847,9 @@ static gboolean parse_RMPP(proto_tree *parentTree, packet_info *pinfo, tvbuff_t
proto_item_set_text(RMPP_header_item, "%s%s", val_to_str(RMPP->Type, RMPP_Packet_Types, "RMPP (Reserved 0x%02x)"), " - Reliable Multi-Packet Transaction Protocol");
proto_item_append_text(RMPP_type_item, " %s", val_to_str(RMPP->Type, RMPP_Packet_Types, "RMPP (Reserved 0x%02x)"));
}
+
+ RMPP->PayloadLength = 0;
+
switch (RMPP->Type) {
case RMPP_ILLEGAL:
proto_tree_add_item(RMPP_header_tree, hf_opa_rmpp_data1, tvb, local_offset, 4, ENC_BIG_ENDIAN);