[ovs-dev] [PATCH] dpif-linux: Fix byte-swapping direction in nl_msg_put_u16() call.

Ben Pfaff blp at nicira.com
Fri Feb 15 21:28:30 UTC 2013


On Fri, Feb 15, 2013 at 01:14:52PM -0800, Jesse Gross wrote:
> On Fri, Feb 15, 2013 at 11:24 AM, Ben Pfaff <blp at nicira.com> wrote:
> > OVS_TUNNEL_ATTR_DST_PORT expects a u16, tnl_cfg->dst_port is a be16, so
> > we want ntohs() instead of htons().
> >
> > In practice htons() and ntohs() perform the same operation, so this does
> > not fix a real bug.
> >
> > Found by sparse.
> >
> > Signed-off-by: Ben Pfaff <blp at nicira.com>
> 
> Looks good to me.

Thanks, applied to master.



More information about the dev mailing list