2
0
mirror of https://github.com/openvswitch/ovs synced 2025-08-31 14:25:26 +00:00

Make attribute packed equivalent for MSC compilers.

Signed-off-by: Linda Sun <lsun@vmware.com>
Signed-off-by: Ben Pfaff <blp@nicira.com>
This commit is contained in:
Linda Sun
2013-07-17 12:08:25 -07:00
committed by Ben Pfaff
parent 00ecc5ced7
commit 13b6bae61e
7 changed files with 52 additions and 22 deletions

View File

@@ -93,4 +93,10 @@
#define OVS_PACKED_ENUM
#endif
#ifndef _MSC_VER
#define OVS_PACKED(DECL) DECL __attribute__((__packed__))
#else
#define OVS_PACKED(DECL) __pragma(pack(push, 1)) DECL __pragma(pack(pop))
#endif
#endif /* compiler.h */