From c392069685c9b6c6dec11cc8f1179a2c4e15be13 Mon Sep 17 00:00:00 2001 From: Simon Hausmann Date: Wed, 18 Sep 2013 21:13:03 +0200 Subject: Allow delayed deallocation in the executable memory allocator Allow for allocations to outlive the allocator itself. When the allocator dies, it invalidates any remaining non-free allocations, making them safe to delete later. Change-Id: I6c71cddbbd5dcaff1ad50f3991a3c710d4f96737 Reviewed-by: Lars Knoll --- src/3rdparty/masm/stubs/ExecutableAllocator.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/3rdparty/masm/stubs/ExecutableAllocator.h') diff --git a/src/3rdparty/masm/stubs/ExecutableAllocator.h b/src/3rdparty/masm/stubs/ExecutableAllocator.h index 4e3be7ca4a..a8f54df39f 100644 --- a/src/3rdparty/masm/stubs/ExecutableAllocator.h +++ b/src/3rdparty/masm/stubs/ExecutableAllocator.h @@ -67,7 +67,7 @@ struct ExecutableMemoryHandle : public RefCounted { } ~ExecutableMemoryHandle() { - m_allocator->free(m_allocation); + m_allocation->deallocate(m_allocator); } inline void shrink(size_t) { -- cgit v1.2.3