diff options
Diffstat (limited to 'include/list.h')
-rw-r--r-- | include/list.h | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/include/list.h b/include/list.h index b1b1ca3..571cd5c 100644 --- a/include/list.h +++ b/include/list.h @@ -1,9 +1,11 @@ #define POISON_POINTER_DELTA 0 -#define LIST_POISON1 ((void *) 0x00100100 + POISON_POINTER_DELTA) -#define LIST_POISON2 ((void *) 0x00200200 + POISON_POINTER_DELTA) +#define LIST_POISON1 ((void *) (0x00100100 + POISON_POINTER_DELTA)) +#define LIST_POISON2 ((void *) (0x00200200 + POISON_POINTER_DELTA)) +#if !defined(offsetof) #define offsetof(TYPE, MEMBER) ((size_t) &((TYPE *)0)->MEMBER) +#endif #define container_of(ptr, type, member) ({ \ const typeof( ((type *)0)->member ) *__mptr = (ptr); \ (type *)( (char *)__mptr - offsetof(type,member) );}) |