From 0c2d03e69f427a3b2285c5b26267004befbcc2a9 Mon Sep 17 00:00:00 2001 From: Brecht Van Lommel Date: Fri, 22 Jan 2010 10:56:50 +0000 Subject: Fix MEM_testN not unlocking mutex correctly, unlikely to lead to problems in practice but might as well fix. --- intern/guardedalloc/intern/mallocn.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'intern') diff --git a/intern/guardedalloc/intern/mallocn.c b/intern/guardedalloc/intern/mallocn.c index 15236a2bee4..342852c4f76 100644 --- a/intern/guardedalloc/intern/mallocn.c +++ b/intern/guardedalloc/intern/mallocn.c @@ -539,8 +539,10 @@ short MEM_testN(void *vmemh) { if (membl) membl = MEMNEXT(membl); while(membl) { - if (vmemh == membl+1) + if (vmemh == membl+1) { + mem_unlock_thread(); return 1; + } if(membl->next) membl= MEMNEXT(membl->next); -- cgit v1.2.3