X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=lib%2Fcompiler.h;fp=lib%2Fcompiler.h;h=4b1834f0fb5e1083984e76be2a972c2d81970d28;hb=13b6bae61ec4e730f8be140711bf783f65db7c1a;hp=f3cbe96e8a09b595396804570d6c79b82993aa7f;hpb=00ecc5ced742db3f5de4101c43f2cfdac7456193;p=sliver-openvswitch.git diff --git a/lib/compiler.h b/lib/compiler.h index f3cbe96e8..4b1834f0f 100644 --- a/lib/compiler.h +++ b/lib/compiler.h @@ -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 */