Commit: 59b4c675361b54b32b6238855fe4a82117cc48c7
Author: Bastien Montagne
Date:   Wed Jul 11 14:32:06 2018 +0200
Branches: master
https://developer.blender.org/rB59b4c675361b54b32b6238855fe4a82117cc48c7

Minor cleanup to logic in BKE's imbuf releasing code.

===================================================================

M       source/blender/blenkernel/intern/image.c

===================================================================

diff --git a/source/blender/blenkernel/intern/image.c 
b/source/blender/blenkernel/intern/image.c
index 76cf7317b19..c520714b076 100644
--- a/source/blender/blenkernel/intern/image.c
+++ b/source/blender/blenkernel/intern/image.c
@@ -4095,12 +4095,12 @@ ImBuf *BKE_image_acquire_ibuf(Image *ima, ImageUser 
*iuser, void **r_lock)
 
 void BKE_image_release_ibuf(Image *ima, ImBuf *ibuf, void *lock)
 {
-       if (lock) {
+       if (lock != NULL) {
                /* for getting image during threaded render / compositing, need 
to release */
                if (lock == ima) {
                        BLI_thread_unlock(LOCK_VIEWER); /* viewer image */
                }
-               else if (lock) {
+               else {
                        RE_ReleaseResultImage(lock); /* render result */
                        BLI_thread_unlock(LOCK_VIEWER); /* view image imbuf */
                }

_______________________________________________
Bf-blender-cvs mailing list
Bf-blender-cvs@blender.org
https://lists.blender.org/mailman/listinfo/bf-blender-cvs

Reply via email to