From da266af7108262a82eb66ea577997a5830dde17e Mon Sep 17 00:00:00 2001 From: Guy Harris Date: Fri, 28 Aug 2015 12:46:11 -0700 Subject: Don't check the radio information when testing for an HT Control header. I now read 8.2.4.1.10 "Order field" in 802.11-2012 as saying that, in management and QoS data frames, the Order bit shouldn't be set for non-HT, non-VHT frames, so we can just test it for those frame types without bothering to check the radio metadata to see if the frame is an HT or VHT frame. This handles cases where the radio metadata isn't complete, e.g. an HT frame with a radiotap header but no MCS field. Handle this for *all* QoS data frames when capturing. Get rid of the "fixed-length link-layer header" stuff; it's not being used. Fix a case where we're appending text to a tree item without a space separating it from the previous text. Bug: 11351 Change-Id: I980f5b7509603b0c22c297fddc19434c08817913 Reviewed-on: https://code.wireshark.org/review/10288 Reviewed-by: Guy Harris --- epan/dissectors/packet-ppi.c | 21 ++------------------- 1 file changed, 2 insertions(+), 19 deletions(-) (limited to 'epan/dissectors/packet-ppi.c') diff --git a/epan/dissectors/packet-ppi.c b/epan/dissectors/packet-ppi.c index 6744969051..2db066a2fb 100644 --- a/epan/dissectors/packet-ppi.c +++ b/epan/dissectors/packet-ppi.c @@ -389,9 +389,7 @@ void capture_ppi(const guchar *pd, int len, packet_counts *ld) { guint32 dlt; - guint ppi_len, data_type, data_len; - guint offset = PPI_V0_HEADER_LEN; - gboolean is_htc = FALSE; + guint ppi_len; ppi_len = pletoh16(pd+2); if(ppi_len < PPI_V0_HEADER_LEN || !BYTES_ARE_IN_FRAME(0, len, ppi_len)) { @@ -401,28 +399,13 @@ capture_ppi(const guchar *pd, int len, packet_counts *ld) dlt = pletoh32(pd+4); - /* Figure out if we're +HTC */ - while (offset < ppi_len) { - data_type = pletoh16(pd+offset); - data_len = pletoh16(pd+offset+2) + 4; - offset += data_len; - - if (data_type == PPI_80211N_MAC || data_type == PPI_80211N_MAC_PHY) { - is_htc = TRUE; - break; - } - } - /* XXX - We should probably combine this with capture_info.c:capture_info_packet() */ switch(dlt) { case 1: /* DLT_EN10MB */ capture_eth(pd, ppi_len, len, ld); return; case 105: /* DLT_DLT_IEEE802_11 */ - if (is_htc) - capture_ieee80211_ht(pd, ppi_len, len, ld); - else - capture_ieee80211(pd, ppi_len, len, ld); + capture_ieee80211(pd, ppi_len, len, ld); return; default: break; -- cgit v1.2.1