[ovs-dev] [PATCH v2] windows/lib: Fix Windows C++ compilation issues on common headers

Ben Pfaff blp at ovn.org
Thu Dec 14 22:12:12 UTC 2017


On Wed, Dec 13, 2017 at 04:13:20PM -0800, Sairam Venugopal wrote:
> Found when compiling the code with C++ binaries. Most of the issues are
> due to missing explicit cast.
> 
> Changes in PADDED_MEMBERS* is because MSVC does not allow to re-define
> unnamed structure in union. Thus, this fix defines the struct outside of
> the anonymous union in order to calculate the padded size.
> 
> Signed-off-by: Sairam Venugopal <vsairam at vmware.com>
> Signed-off-by: Shireesh Kumar Singh <shireeshkum at vmware.com>
> Co-authored-by: Shireesh Kumar Singh <shireeshkum at vmware.com>

Thanks for working on this.

I think that this should actually be a series of patches:

        - PADDED_MEMBERS fix.

        - Added casts

        - Changes to types in the atomics header.

        - Initializer changes.

        - BUILD_ASSERT change.  I think that this change should actually
          be a change to the BUILD_ASSERT macro.  It does not make sense
          to change just one user.

Thanks,

Ben.


More information about the dev mailing list