]> granicus.if.org Git - libx264/commitdiff
don't define offsetof since it's standard
authorLoren Merritt <pengvado@akuvian.org>
Mon, 17 Mar 2008 21:41:30 +0000 (15:41 -0600)
committerLoren Merritt <pengvado@akuvian.org>
Mon, 17 Mar 2008 21:41:30 +0000 (15:41 -0600)
common/common.h

index 2c905b53f7b57498cd1d8d7598f4864893a85908..584bcd76573e4ca4dd1483bc27f0adac8959a50a 100644 (file)
 #define XCHG(type,a,b) { type t = a; a = b; b = t; }
 #define FIX8(f) ((int)(f*(1<<8)+.5))
 
-#ifndef offsetof
-#define offsetof(T,F) ((unsigned long)((char *)&((T *)0)->F))
-#endif
-
 #define CHECKED_MALLOC( var, size )\
 {\
     var = x264_malloc( size );\
@@ -64,6 +60,7 @@
  ****************************************************************************/
 #include "osdep.h"
 #include <stdarg.h>
+#include <stddef.h>
 #include <stdlib.h>
 #include <string.h>
 #include <assert.h>