aboutsummaryrefslogtreecommitdiffstats
path: root/epan/dissectors/packet-ieee1722.c
diff options
context:
space:
mode:
authorAlexis La Goutte <alexis.lagoutte@gmail.com>2016-08-21 16:21:40 +0200
committerMichael Mann <mmann78@netscape.net>2016-08-21 14:57:43 +0000
commit7804be057e882345c0e1fba28fde01c977123abb (patch)
tree8ac27a91aa92d45de9298a34254c7664a044eba4 /epan/dissectors/packet-ieee1722.c
parent07611921bea711baa8b460c3b2f1a91b1279a799 (diff)
ieee1722: fix Division by Zero found by Clang Analyzer and Coverity (CID 1371610)
Change-Id: Iac0ef122062f8dc3160e112d76c35a256f8d8c2a Reviewed-on: https://code.wireshark.org/review/17201 Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com> Reviewed-by: Michael Mann <mmann78@netscape.net>
Diffstat (limited to 'epan/dissectors/packet-ieee1722.c')
-rw-r--r--epan/dissectors/packet-ieee1722.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/epan/dissectors/packet-ieee1722.c b/epan/dissectors/packet-ieee1722.c
index ae2ef130f5..d03936a2c6 100644
--- a/epan/dissectors/packet-ieee1722.c
+++ b/epan/dissectors/packet-ieee1722.c
@@ -1089,7 +1089,7 @@ static int dissect_1722_aaf (tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree
ti = proto_tree_add_item(ti_aaf_tree, hf_1722_aaf_data, tvb, offset, datalen, ENC_NA);
ti_audio_tree = proto_item_add_subtree(ti, ett_1722_aaf_audio);
- if (sample_width == 0)
+ if (sample_width == 0 || channels_per_frame == 0)
{
expert_add_info(pinfo, ti, &ei_aaf_sample_width);
}