forked from osmocom/wireshark
IEEE80211-radio: Fix divide by zero
Perform sanity check on parsed data rate. Data rate of zero results in a division by zero in calculate_llac_duration. Do not use data rate if zero. Bug: 13706 Change-Id: I7883e1052a0965f7927d3a478c0aa992693f7fe1 Reviewed-on: https://code.wireshark.org/review/21626 Reviewed-by: Peter Wu <peter@lekensteyn.nl> Petri-Dish: Peter Wu <peter@lekensteyn.nl> Reviewed-by: Guy Harris <guy@alum.mit.edu> Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org> Reviewed-by: Michael Mann <mmann78@netscape.net>
This commit is contained in:
parent
544ebca89d
commit
bd3e24f0da
|
@ -882,7 +882,7 @@ dissect_wlan_radio_phdr (tvbuff_t * tvb, packet_info * pinfo, proto_tree * tree,
|
|||
frame_length += 4;
|
||||
}
|
||||
|
||||
if (have_data_rate) {
|
||||
if (have_data_rate && data_rate > 0) {
|
||||
/* duration calculations */
|
||||
gboolean assumed_short_preamble = FALSE;
|
||||
gboolean assumed_non_greenfield = FALSE;
|
||||
|
|
Loading…
Reference in New Issue