On 04/12/2014 10:09 PM, Thomas F Herbert wrote:
diff --git a/lib/packets.c b/lib/packets.c
index 6244c3f..385da79 100644
--- a/lib/packets.c
+++ b/lib/packets.c
@@ -198,8 +198,9 @@ eth_pop_vlan(struct ofpbuf *packet)
{
struct vlan_eth_header *veh = ofpbuf_l2(packet);
- if (veh && ofpbuf_size(packet) >= sizeof *veh
- && veh->veth_type == htons(ETH_TYPE_VLAN)) {
+ if (packet->size >= sizeof *veh &&
+ ((veh->veth_type == htons(ETH_TYPE_VLAN_8021Q)) ||
+ ((veh->veth_type == htons(ETH_TYPE_VLAN_8021AD))))) {
memmove((char *)veh + VLAN_HEADER_LEN, veh, 2 * ETH_ADDR_LEN);
ofpbuf_resize_l2(packet, -VLAN_HEADER_LEN);
Can you indent the above properly when you rebase?
_______________________________________________
dev mailing list
dev@openvswitch.org
http://openvswitch.org/mailman/listinfo/dev