Attempt to fix guardedalloc on OSX
authorSergey Sharybin <sergey.vfx@gmail.com>
Fri, 13 Jun 2014 19:52:02 +0000 (01:52 +0600)
committerSergey Sharybin <sergey.vfx@gmail.com>
Fri, 13 Jun 2014 19:52:35 +0000 (01:52 +0600)
intern/guardedalloc/intern/mallocn.c
intern/guardedalloc/intern/mallocn_intern.h

index b0d252cca1453f16f51fba5014356506b12a8bda..40f406d0ae26bc26b5657acea580241025e1a9c5 100644 (file)
@@ -32,6 +32,8 @@
 /* to ensure strict conversions */
 #include "../../source/blender/blenlib/BLI_strict_flags.h"
 
+#include <assert.h>
+
 #include "mallocn_intern.h"
 
 size_t (*MEM_allocN_len)(const void *vmemh) = MEM_lockfree_allocN_len;
index a69bcf3d27b2ad123355f8a86a56cf66b4b7cd66..523d1786b9712ce2da82a39691bcc3bc7187060b 100644 (file)
 #else
 // Apple's malloc is 16-byte aligned, and does not have malloc.h, so include
 // stdilb instead.
-#  include <cstdlib>
+#  include <stdlib.h>
 #endif
 
 #define IS_POW2(a) (((a) & ((a) - 1)) == 0)