X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=lib%2Futil.h;h=0e9353dbd5c42056eae02da2d283480cdabdab8a;hb=55cc89d6b427ca99dbc1217653033e6308318409;hp=9df6db5836833522dfeb955fa98e19354f232fda;hpb=a0bc29a541fc7dc6e20137d5558e2094d614e6ab;p=sliver-openvswitch.git diff --git a/lib/util.h b/lib/util.h index 9df6db583..0e9353dbd 100644 --- a/lib/util.h +++ b/lib/util.h @@ -80,7 +80,7 @@ extern const char *program_name; /* Given POINTER, the address of the given MEMBER in a STRUCT object, returns the STRUCT object. */ #define CONTAINER_OF(POINTER, STRUCT, MEMBER) \ - ((STRUCT *) ((char *) (POINTER) - offsetof (STRUCT, MEMBER))) + ((STRUCT *) (void *) ((char *) (POINTER) - offsetof (STRUCT, MEMBER))) #ifdef __cplusplus extern "C" {