dde_linux: prevent debug message in memory backend

The Allocator_avl back end will display diagnostic messages if the
address to be freed is not at the beginning of a block. This happens
regulary when 'struct page' objects are not freed in allocation order.

Issue #4325.
This commit is contained in:
Josef Söntgen 2021-11-12 16:30:34 +01:00 committed by Christian Helmuth
parent 98385a7658
commit 059c7ed74a

View File

@ -167,6 +167,9 @@ bool Lx_kit::Mem_allocator::free(const void * ptr)
if (!_mem.valid_addr((addr_t)ptr))
return false;
if (!_mem.size_at(ptr))
return true;
_mem.free(const_cast<void*>(ptr));
return true;
}