fix offsetof

This commit is contained in:
Yuichi Nishiwaki
2016-02-21 01:47:08 +09:00
parent 8dd423cdbc
commit 66717f2b43
+1 -1
View File
@@ -104,7 +104,7 @@
#if __STDC_VERSION__ >= 199901L
# include <stddef.h>
#elif ! defined(offsetof)
# define offsetof(s,m) ((size_t)&(((s *)NULL)->m))
# define offsetof(s,m) ((size_t)(&(((s *)0)->m) - 0))
#endif
#if __STDC_VERSION__ >= 199901L