net: avoid cast-align warning in VLAN insert function
[dpdk.git] / lib / net / rte_ether.h
index 2c7da55..1a0dbf0 100644 (file)
@@ -367,7 +367,7 @@ static inline int rte_vlan_insert(struct rte_mbuf **m)
                return -EINVAL;
 
        oh = rte_pktmbuf_mtod(*m, struct rte_ether_hdr *);
-       nh = (struct rte_ether_hdr *)
+       nh = (struct rte_ether_hdr *)(void *)
                rte_pktmbuf_prepend(*m, sizeof(struct rte_vlan_hdr));
        if (nh == NULL)
                return -ENOSPC;