diff --git a/src/test/func/fixed_region/fixed_region.cc b/src/test/func/fixed_region/fixed_region.cc index e8f6c97b0..31b303f82 100644 --- a/src/test/func/fixed_region/fixed_region.cc +++ b/src/test/func/fixed_region/fixed_region.cc @@ -40,12 +40,15 @@ int main() { auto r1 = a.alloc(object_size); - if (SecondaryAllocator::has_secondary_ownership(r1)) - continue; - count += object_size; i++; + if (SecondaryAllocator::has_secondary_ownership(r1)) + { + a.dealloc(r1); + continue; + } + if (i == 1024) { i = 0;