[Bf-blender-cvs] [f2d7356f162] master: Background Fit could set inf zoom
Campbell Barton
noreply at git.blender.org
Mon May 29 18:45:26 CEST 2017
Commit: f2d7356f162670f6e0162983ecc41ca681b9e267
Author: Campbell Barton
Date: Tue May 30 02:39:07 2017 +1000
Branches: master
https://developer.blender.org/rBf2d7356f162670f6e0162983ecc41ca681b9e267
Background Fit could set inf zoom
===================================================================
M source/blender/editors/space_node/node_view.c
===================================================================
diff --git a/source/blender/editors/space_node/node_view.c b/source/blender/editors/space_node/node_view.c
index 9c73af12e3f..f497a06cb12 100644
--- a/source/blender/editors/space_node/node_view.c
+++ b/source/blender/editors/space_node/node_view.c
@@ -345,7 +345,7 @@ static int backimage_fit_exec(bContext *C, wmOperator *UNUSED(op))
ima = BKE_image_verify_viewer(IMA_TYPE_COMPOSITE, "Viewer Node");
ibuf = BKE_image_acquire_ibuf(ima, NULL, &lock);
- if (ibuf == NULL) {
+ if ((ibuf == NULL) || (ibuf->x == 0) || (ibuf->y == 0)) {
BKE_image_release_ibuf(ima, ibuf, lock);
return OPERATOR_CANCELLED;
}
More information about the Bf-blender-cvs
mailing list