forked from Imagelibrary/rtems
2009-08-18 Joel Sherrill <joel.sherrill@OARcorp.com>
* sp63/init.c, sp63/sp63.scn: Add case for math on size requested overflowing on _Heap_Allocate_aligned.
This commit is contained in:
@@ -1,3 +1,8 @@
|
||||
2009-08-18 Joel Sherrill <joel.sherrill@OARcorp.com>
|
||||
|
||||
* sp63/init.c, sp63/sp63.scn: Add case for math on size requested
|
||||
overflowing on _Heap_Allocate_aligned.
|
||||
|
||||
2009-08-18 Joel Sherrill <joel.sherrill@OARcorp.com>
|
||||
|
||||
* spobjgetnext/init.c, spobjgetnext/spobjgetnext.scn: Add error cases
|
||||
|
||||
@@ -31,6 +31,10 @@ void test_case_one(void)
|
||||
heap_size = _Heap_Initialize( &Heap, Memory, sizeof(Memory), 8 );
|
||||
printf( "Init - Heap size=%d\n", heap_size );
|
||||
|
||||
puts( "Init - _Heap_Allocate - too large size (overflow)- not OK");
|
||||
ptr1 = _Heap_Allocate( &Heap, 0xffffffff );
|
||||
assert( !ptr1 );
|
||||
|
||||
puts( "Init - _Heap_Allocate_aligned - OK");
|
||||
ptr1 = _Heap_Allocate_aligned( &Heap, 64, 32 );
|
||||
assert( ptr1 );
|
||||
|
||||
@@ -1,11 +1,13 @@
|
||||
*** TEST 63 ***
|
||||
Init - _Heap_Initialize (for test one) - OK
|
||||
Init - Heap size=1012
|
||||
Init - Heap size=1000
|
||||
Init - _Heap_Allocate - too large size (overflow)- not OK
|
||||
Init - _Heap_Allocate_aligned - OK
|
||||
Init - _Heap_Resize_block - OK
|
||||
|
||||
Init - _Heap_Initialize (for test two) - OK
|
||||
Init - Heap size=1012
|
||||
Init - Heap size=1000
|
||||
Init - _Heap_Allocate_aligned - OK
|
||||
Init - _Heap_Resize_block - OK
|
||||
Init - _Heap_Allocate_aligned - request impossible - not OK
|
||||
*** END OF TEST 63 ***
|
||||
|
||||
Reference in New Issue
Block a user