multi_heap: ensure that malloc(0) return NULL pointer in any poisoning configuration
This commit is contained in:
@@ -159,4 +159,11 @@ TEST_CASE("Capabilities aligned calloc test", "[heap]")
|
||||
}
|
||||
#endif
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
TEST_CASE("aligned_alloc(0) should return a NULL pointer", "[heap]")
|
||||
{
|
||||
void *p;
|
||||
p = heap_caps_aligned_alloc(32, 0, MALLOC_CAP_DEFAULT);
|
||||
TEST_ASSERT(p == NULL);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user