On Fri, Jul 11, 2014 at 01:05:03AM +0000, Alin Serdean wrote: > Bypass ALIGNED_CAST on CMSG_DATA when compiling on MSVC. Ignore the code > behind netdev_linux_rxq_drain as well. > > Signed-off-by: Alin Gabriel Serdean <aserd...@cloudbasesolutions.com> > --- > lib/netdev-linux.c | 4 ++++ > 1 file changed, 4 insertions(+) > > diff --git a/lib/netdev-linux.c b/lib/netdev-linux.c > index 1780639..1b2196f 100644 > --- a/lib/netdev-linux.c > +++ b/lib/netdev-linux.c > @@ -949,7 +949,9 @@ netdev_linux_rxq_recv_sock(int fd, struct ofpbuf *buffer) > continue; > } > > +#ifndef _WIN32 > aux = ALIGNED_CAST(struct tpacket_auxdata *, CMSG_DATA(cmsg)); > +#endif > if (auxdata_has_vlan_tci(aux)) { > if (retval < ETH_HEADER_LEN) { > return EINVAL;
This makes no sense because it never initializes 'aux' yet passes it to auxdata_has_vlan_tci(), which dereferences it. > @@ -1032,6 +1034,7 @@ netdev_linux_rxq_wait(struct netdev_rxq *rxq_) > static int > netdev_linux_rxq_drain(struct netdev_rxq *rxq_) > { > +#ifndef _WIN32 > struct netdev_rxq_linux *rx = netdev_rxq_linux_cast(rxq_); > if (rx->is_tap) { > struct ifreq ifr; > @@ -1045,6 +1048,7 @@ netdev_linux_rxq_drain(struct netdev_rxq *rxq_) > } else { > return drain_rcvbuf(rx->fd); > } > +#endif > } Why is netdev_linux_rxq_drain() being disabled? (I noticed that many of your commit messages explain what the commit does. That is often obvious from the diff. It is more useful to explain the reason for the change.) _______________________________________________ dev mailing list dev@openvswitch.org http://openvswitch.org/mailman/listinfo/dev