summaryrefslogtreecommitdiffstats
path: root/testsuites/libtests/malloc04
diff options
context:
space:
mode:
authorJoel Sherrill <joel.sherrill@OARcorp.com>2011-05-05 16:45:47 +0000
committerJoel Sherrill <joel.sherrill@OARcorp.com>2011-05-05 16:45:47 +0000
commit6f27ba8077b83c9e00d0b297eb18e9f08c8225a8 (patch)
treefa7dbf84cc523c17ade54bdde4976dd662d827b2 /testsuites/libtests/malloc04
parent2011-05-05 Joel Sherrill <joel.sherrill@oarcorp.com> (diff)
downloadrtems-6f27ba8077b83c9e00d0b297eb18e9f08c8225a8.tar.bz2
2011-05-05 Joel Sherrill <joel.sherrill@oarcorp.com>
* devnullfatal01/testcase.h, malloc02/init.c, malloc04/init.c, malloctest/init.c, termios03/termios_testdriver_polled.c, termios04/termios_testdriver_intr.c: Remove warnings.
Diffstat (limited to 'testsuites/libtests/malloc04')
-rw-r--r--testsuites/libtests/malloc04/init.c11
1 files changed, 10 insertions, 1 deletions
diff --git a/testsuites/libtests/malloc04/init.c b/testsuites/libtests/malloc04/init.c
index d8e2c9d701..f5d371812d 100644
--- a/testsuites/libtests/malloc04/init.c
+++ b/testsuites/libtests/malloc04/init.c
@@ -1,5 +1,5 @@
/*
- * COPYRIGHT (c) 1989-2010.
+ * COPYRIGHT (c) 1989-2011.
* On-Line Applications Research Corporation (OAR).
*
* The license and distribution terms for this file may be
@@ -111,15 +111,23 @@ rtems_task Init(
sbrk_count = 0;
RTEMS_Malloc_Initialize( NULL, 0, 64 );
p1 = malloc(64);
+ rtems_test_assert( p1 );
+
p2 = malloc(64);
+ rtems_test_assert( p2 );
+
p3 = malloc(48);
+ rtems_test_assert( p3 );
+
p4 = malloc(48);
+ rtems_test_assert( p4 );
puts( "Initialize heap with no memory (sbrk aligned)" );
offset = 0;
sbrk_count = 0;
RTEMS_Malloc_Initialize( NULL, 0, 64 );
p1 = malloc(64);
+ rtems_test_assert( p1 );
puts( "Set sbrk amount in heap to 0" );
offset = 0;
@@ -127,6 +135,7 @@ rtems_task Init(
RTEMS_Malloc_Initialize( NULL, 0, 64 );
RTEMS_Malloc_Sbrk_amount = 0;
p4 = malloc(48);
+ rtems_test_assert( p4 );
/* Restore information on real heap */
malloc_set_heap_pointer( TempHeap );