Images: fix error in previous refactor
Some compositor tests (e.g. `compositor_color_test`) broke because of rB0c3b215e7d5456878b155d13440864f49ad1f230. The issue was a heap-use-after-free bug caused by a missing call to `MEM_CacheLimiter_unmanage`.
This commit is contained in:
@@ -122,8 +122,8 @@ static void moviecache_valfree(void *val)
|
||||
|
||||
PRINT("%s: cache '%s' free item %p buffer %p\n", __func__, cache->name, item, item->ibuf);
|
||||
|
||||
MEM_CacheLimiter_unmanage(item->c_handle);
|
||||
if (item->ibuf) {
|
||||
MEM_CacheLimiter_unmanage(item->c_handle);
|
||||
IMB_freeImBuf(item->ibuf);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user