Mark the "vlan_eth_header" struct as packed, because it's getting padded on some...
authorJustin Pettit <jpettit@nicira.com>
Wed, 7 May 2008 05:11:06 +0000 (22:11 -0700)
committerJustin Pettit <jpettit@nicira.com>
Wed, 7 May 2008 05:20:58 +0000 (22:20 -0700)
-- Reported by GigaFin --

include/packets.h

index ea30a2a..b4a5f05 100644 (file)
@@ -120,7 +120,7 @@ struct vlan_eth_header {
     uint16_t veth_type;         /* Always htons(ETH_TYPE_VLAN). */
     uint16_t veth_tci;          /* Lowest 12 bits are VLAN ID. */
     uint16_t veth_next_type;
-};
+} __attribute__((packed));
 BUILD_ASSERT_DECL(VLAN_ETH_HEADER_LEN == sizeof(struct vlan_eth_header));
 
 #define IP_FMT "%"PRIu8".%"PRIu8".%"PRIu8".%"PRIu8