* support/regression/tests/bug1057979.c, support/regression/tests/malloc.c,
[fw/sdcc] / support / regression / tests / malloc.c
index 593f8c5e0d706442b90d3d779201fb0c8d96c262..bbc36a0b4413dbdb19d7a38e89a0db1b5567afd3 100644 (file)
@@ -1,12 +1,14 @@
 /* Simple malloc tests.
  */
-#include <testfwk.h>
 #include <stdlib.h>
 #if defined(SDCC_pic16)
 #include <malloc.h>
 #endif
+#include <testfwk.h>
 
+#if defined(SDCC_pic16)
 xdata char heap[100];
+#endif
 
 void
 testMalloc(void)
@@ -18,11 +20,9 @@ testMalloc(void)
 #if !defined(__GNUC__) && !defined(SDCC_gbz80) && !defined(SDCC_z80)
 #if defined(SDCC_pic16)
   _initHeap(heap, sizeof heap);
-#else
-  init_dynamic_memory(heap, sizeof(heap));
 #endif
 
-  p1 = malloc(200);
+  p1 = malloc(2000);
   ASSERT(p1 == NULL);
   LOG(("p1 == NULL when out of memory\n"));
 #ifdef PORT_HOST