|
@@ -37,7 +37,7 @@
|
|
|
// constants
|
|
|
//
|
|
|
#define U_ETHER_ADDR_STR_LEN (ETH_ALEN * 2 + 1)
|
|
|
- // Ethernet address string length
|
|
|
+// Ethernet address string length
|
|
|
|
|
|
#define MAX_LOOKAHEAD_SIZE ETH_FRAME_LEN
|
|
|
|
|
@@ -151,10 +151,10 @@
|
|
|
// Ethernet packet
|
|
|
//
|
|
|
typedef struct tagSEthernetHeader {
|
|
|
- unsigned char abyDstAddr[ETH_ALEN];
|
|
|
- unsigned char abySrcAddr[ETH_ALEN];
|
|
|
- unsigned short wType;
|
|
|
-}__attribute__ ((__packed__))
|
|
|
+ unsigned char abyDstAddr[ETH_ALEN];
|
|
|
+ unsigned char abySrcAddr[ETH_ALEN];
|
|
|
+ unsigned short wType;
|
|
|
+} __attribute__ ((__packed__))
|
|
|
SEthernetHeader, *PSEthernetHeader;
|
|
|
|
|
|
|
|
@@ -162,24 +162,24 @@ SEthernetHeader, *PSEthernetHeader;
|
|
|
// 802_3 packet
|
|
|
//
|
|
|
typedef struct tagS802_3Header {
|
|
|
- unsigned char abyDstAddr[ETH_ALEN];
|
|
|
- unsigned char abySrcAddr[ETH_ALEN];
|
|
|
- unsigned short wLen;
|
|
|
-}__attribute__ ((__packed__))
|
|
|
+ unsigned char abyDstAddr[ETH_ALEN];
|
|
|
+ unsigned char abySrcAddr[ETH_ALEN];
|
|
|
+ unsigned short wLen;
|
|
|
+} __attribute__ ((__packed__))
|
|
|
S802_3Header, *PS802_3Header;
|
|
|
|
|
|
//
|
|
|
// 802_11 packet
|
|
|
//
|
|
|
typedef struct tagS802_11Header {
|
|
|
- unsigned short wFrameCtl;
|
|
|
- unsigned short wDurationID;
|
|
|
- unsigned char abyAddr1[ETH_ALEN];
|
|
|
- unsigned char abyAddr2[ETH_ALEN];
|
|
|
- unsigned char abyAddr3[ETH_ALEN];
|
|
|
- unsigned short wSeqCtl;
|
|
|
- unsigned char abyAddr4[ETH_ALEN];
|
|
|
-}__attribute__ ((__packed__))
|
|
|
+ unsigned short wFrameCtl;
|
|
|
+ unsigned short wDurationID;
|
|
|
+ unsigned char abyAddr1[ETH_ALEN];
|
|
|
+ unsigned char abyAddr2[ETH_ALEN];
|
|
|
+ unsigned char abyAddr3[ETH_ALEN];
|
|
|
+ unsigned short wSeqCtl;
|
|
|
+ unsigned char abyAddr4[ETH_ALEN];
|
|
|
+} __attribute__ ((__packed__))
|
|
|
S802_11Header, *PS802_11Header;
|
|
|
|
|
|
/*--------------------- Export Macros ------------------------------*/
|