From 8ff4c53e63dc1eb7f4855915dd45d044b854e301 Mon Sep 17 00:00:00 2001 From: Sergey Sharybin Date: Fri, 20 Mar 2015 21:09:52 +0500 Subject: Correction to previous commit, initialization of needs_free got lost by accident --- source/blender/render/intern/source/external_engine.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/source/blender/render/intern/source/external_engine.c b/source/blender/render/intern/source/external_engine.c index c66b9c2ce0d..653f3f0786a 100644 --- a/source/blender/render/intern/source/external_engine.c +++ b/source/blender/render/intern/source/external_engine.c @@ -379,10 +379,11 @@ rcti* RE_engine_get_current_tiles(Render *re, int *total_tiles_r, bool *r_needs_ BLI_rw_mutex_lock(&re->partsmutex, THREAD_LOCK_READ); + *r_needs_free = false; + if (re->engine && (re->engine->flag & RE_ENGINE_HIGHLIGHT_TILES) == 0) { *total_tiles_r = 0; BLI_rw_mutex_unlock(&re->partsmutex); - *r_needs_free = false; return NULL; } @@ -398,6 +399,7 @@ rcti* RE_engine_get_current_tiles(Render *re, int *total_tiles_r, bool *r_needs_ tiles = MEM_reallocN(tiles, (total_tiles + allocation_step) * sizeof(rcti)); allocation_size += allocation_step; + *r_needs_free = true; } tiles[total_tiles] = pa->disprect; -- cgit v1.2.3