]> The Tcpdump Group git mirrors - tcpdump/commitdiff
Process the flags even if parsing the full radiotap header fails.
authorGuy Harris <[email protected]>
Tue, 5 Apr 2011 04:32:58 +0000 (21:32 -0700)
committerGuy Harris <[email protected]>
Tue, 5 Apr 2011 04:32:58 +0000 (21:32 -0700)
If we were able to get the flags, we should process them, so we know
whether there's Atheros padding after the 802.11 header or if there's an
FCS at the end of the packet, and properly process them; if we weren't
able to get the flags, they're 0, so we're not doing anything
differently, and that's the best we can do.

print-802_11.c

index 81e0332ee94a8952067061f1ff68a968367f3f6f..385e6cb63ebe4a8243c89520a98edde1623110d6 100644 (file)
@@ -1677,11 +1677,11 @@ ieee802_11_radio_print(const u_char *p, u_int length, u_int caplen)
                }
        }
 
+out:
        if (flags & IEEE80211_RADIOTAP_F_DATAPAD)
                pad = 1;        /* Atheros padding */
        if (flags & IEEE80211_RADIOTAP_F_FCS)
                fcslen = 4;     /* FCS at end of packet */
-out:
        return len + ieee802_11_print(p + len, length - len, caplen - len, pad,
            fcslen);
 #undef BITNO_32