diff options
Diffstat (limited to 'core/pool_allocator.cpp')
-rw-r--r-- | core/pool_allocator.cpp | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/core/pool_allocator.cpp b/core/pool_allocator.cpp index 48a30f6702..6c1f2756f2 100644 --- a/core/pool_allocator.cpp +++ b/core/pool_allocator.cpp @@ -204,10 +204,8 @@ PoolAllocator::ID PoolAllocator::alloc(int p_size) { /* Then search again */ if (!find_hole(&new_entry_indices_pos, size_to_alloc)) { - mt_unlock(); - ERR_EXPLAIN("Memory can't be compacted further"); - ERR_FAIL_V(POOL_ALLOCATOR_INVALID_ID); + ERR_FAIL_V_MSG(POOL_ALLOCATOR_INVALID_ID, "Memory can't be compacted further."); } } @@ -217,8 +215,7 @@ PoolAllocator::ID PoolAllocator::alloc(int p_size) { if (!found_free_entry) { mt_unlock(); - ERR_EXPLAIN("No free entry found in PoolAllocator"); - ERR_FAIL_V(POOL_ALLOCATOR_INVALID_ID); + ERR_FAIL_V_MSG(POOL_ALLOCATOR_INVALID_ID, "No free entry found in PoolAllocator."); } /* move all entry indices up, make room for this one */ |