From: Simon Hausmann Date: Sat, 1 Jun 2013 12:27:45 +0000 (+0200) Subject: valgrind support: Destroy mempool when memoryManager is destroyed X-Git-Tag: upstream/5.2.1~669^2~355 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=b32da633e09feeabc336efe54faa2a8c55b6abb4;p=platform%2Fupstream%2Fqtdeclarative.git valgrind support: Destroy mempool when memoryManager is destroyed Fixes "impossible situation!" abort in valgrind when running tests that create and destroy a lot of engines. Change-Id: I58cfd2380b0149d25ebecdb270be428ec6b8a64f Reviewed-by: Lars Knoll --- diff --git a/src/qml/qml/v4/qv4mm.cpp b/src/qml/qml/v4/qv4mm.cpp index 4386382..c3942a9 100644 --- a/src/qml/qml/v4/qv4mm.cpp +++ b/src/qml/qml/v4/qv4mm.cpp @@ -472,6 +472,9 @@ MemoryManager::~MemoryManager() } sweep(); +#ifdef V4_USE_VALGRIND + VALGRIND_DESTROY_MEMPOOL(this); +#endif } void MemoryManager::protect(Managed *m)