On 7 August 2015 at 16:57, Jarno Rajahalme <jrajaha...@nicira.com> wrote: > GCC (4.7) sees too wide shifts when there are none, refactor to > circumvent the false error. > > Signed-off-by: Jarno Rajahalme <jrajaha...@nicira.com> > --- > lib/flow.c | 35 ++++++++++++++++++++++------------- > 1 file changed, 22 insertions(+), 13 deletions(-) > > diff --git a/lib/flow.c b/lib/flow.c > index af51aac..61d9bdf 100644 > --- a/lib/flow.c > +++ b/lib/flow.c > @@ -133,25 +133,34 @@ BUILD_MESSAGE("FLOW_WC_SEQ changed: miniflow_extract() > will have runtime " > #endif > > #define miniflow_set_map(MF, OFS) \ > - if ((OFS) < FLOW_TNL_U64S) { \ > - MINIFLOW_ASSERT(!(MF.maps.tnl_map & (UINT64_MAX << (OFS))) \ > +{ \ > + size_t ofs = (OFS); \ > + \
Being a bit pedantic here, but don't we usually use 'size_t' to indicate a length in bytes? Seems like 'unsigned int' would be more appropriate for bit-shifting. Acked-by: Joe Stringer <joestrin...@nicira.com> _______________________________________________ dev mailing list dev@openvswitch.org http://openvswitch.org/mailman/listinfo/dev