Index: /trunk/include/iprt/types.h
===================================================================
--- /trunk/include/iprt/types.h	(revision 40945)
+++ /trunk/include/iprt/types.h	(revision 40946)
@@ -41,4 +41,5 @@
 RT_C_DECLS_BEGIN
 #  include "xf86_ansic.h"
+#  undef NULL
 RT_C_DECLS_END
 
@@ -149,9 +150,19 @@
 #  undef true
 #  undef bool
-
 # else
 #  include <stddef.h>
 #  include <sys/types.h>
 # endif
+
+
+/* Define any types missing from sys/types.h on windows. */
+# ifdef _MSC_VER
+#  undef ssize_t
+   typedef intptr_t ssize_t;
+# endif
+
+#else  /* no crt */
+# include <iprt/nocrt/compiler/compiler.h>
+#endif /* no crt */
 
 /** @def NULL
@@ -165,14 +176,4 @@
 # endif
 #endif
-
-/* Define any types missing from sys/types.h on windows. */
-# ifdef _MSC_VER
-#  undef ssize_t
-   typedef intptr_t ssize_t;
-# endif
-
-#else  /* no crt */
-# include <iprt/nocrt/compiler/compiler.h>
-#endif /* no crt */
 
 
