On Tue, May 23, 2017 at 04:02:13PM -0700, Joe Stringer wrote: > Clang 4.0 complains: > > ../ofproto/ofproto-dpif.c:2291:46: error: taking address of packed member > 'eth_src' of class or structure 'eth_header' may result in an unaligned > pointer > value > [-Werror,-Waddress-of-packed-member] > netdev_get_etheraddr(ofport->up.netdev, ð->eth_src); > ^~~~~~~~~~~~ > ../ofproto/ofproto-dpif.c:2316:50: error: taking address of packed member > 'eth_src' of class or structure 'eth_header' may result in an unaligned > pointer > value > [-Werror,-Waddress-of-packed-member] > netdev_get_etheraddr(ofport->up.netdev, ð->eth_src); > > Ethernet source addresses are 48 bits offset into the Ethernet header, > so taking a pointer for this is not guaranteed to be valid on all > architectures. Fix this by retrieving the mac address to the local stack > and copying it into the header. > > Signed-off-by: Joe Stringer <[email protected]>
Hmm, I still don't understand what's packed here. _______________________________________________ dev mailing list [email protected] https://mail.openvswitch.org/mailman/listinfo/ovs-dev
