throw_bad_alloc in expand_bwd_test_allocator::allocation_command in case of a bad request

This commit is contained in:
Ion Gaztañaga
2022-08-24 14:48:59 +02:00
parent 49a028bfe9
commit 8b27fefb8e

View File

@@ -137,6 +137,7 @@ class expand_bwd_test_allocator
if(m_allocations == 0){
if((m_offset + limit_size) > m_size){
assert(0);
throw_bad_alloc();
}
++m_allocations;
reuse = 0;