Re: [ovs-dev] [PATCH] learn: learn_spec fixes.

2016-09-01 Thread Jarno Rajahalme
> On Sep 1, 2016, at 1:18 PM, Ben Pfaff wrote: > > On Thu, Sep 01, 2016 at 01:10:37PM -0700, Jarno Rajahalme wrote: >> Avoid using nested zero-sized arrays to allow compilation with MSVC. >> Also, make sure the immediate data is accessed only if it exists, and >> that the size is always calculat

Re: [ovs-dev] [PATCH] learn: learn_spec fixes.

2016-09-01 Thread Ben Pfaff
On Thu, Sep 01, 2016 at 01:18:55PM -0700, Ben Pfaff wrote: > On Thu, Sep 01, 2016 at 01:10:37PM -0700, Jarno Rajahalme wrote: > > Avoid using nested zero-sized arrays to allow compilation with MSVC. > > Also, make sure the immediate data is accessed only if it exists, and > > that the size is alway

Re: [ovs-dev] [PATCH] learn: learn_spec fixes.

2016-09-01 Thread Ben Pfaff
On Thu, Sep 01, 2016 at 01:10:37PM -0700, Jarno Rajahalme wrote: > Avoid using nested zero-sized arrays to allow compilation with MSVC. > Also, make sure the immediate data is accessed only if it exists, and > that the size is always calculated from struct learn_spec field > 'n_bits'. > > Reported

[ovs-dev] [PATCH] learn: learn_spec fixes.

2016-09-01 Thread Jarno Rajahalme
Avoid using nested zero-sized arrays to allow compilation with MSVC. Also, make sure the immediate data is accessed only if it exists, and that the size is always calculated from struct learn_spec field 'n_bits'. Reported-by: Alin Serdean Signed-off-by: Jarno Rajahalme --- include/openvswitch/o