Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCampbell Barton <ideasman42@gmail.com>2020-02-25 08:59:57 +0300
committerCampbell Barton <ideasman42@gmail.com>2020-02-25 09:02:41 +0300
commit096936fe1d42e8ef49000ad05d6ea5f63f529015 (patch)
tree0eab7acd3514c38a421d40df6fe17f8d41623a4f
parent727d430811e2911167778aa7ab612e810c1990c2 (diff)
Fix T74182: Crash saving images from non-image spaces
-rw-r--r--source/blender/editors/space_image/image_buttons.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/source/blender/editors/space_image/image_buttons.c b/source/blender/editors/space_image/image_buttons.c
index 270fe0c59dc..454546cf34f 100644
--- a/source/blender/editors/space_image/image_buttons.c
+++ b/source/blender/editors/space_image/image_buttons.c
@@ -855,7 +855,7 @@ void uiTemplateImage(uiLayout *layout,
/* Disable editing if image was modified, to avoid losing changes. */
const bool is_dirty = BKE_image_is_dirty(ima);
- if (is_dirty) {
+ if (is_dirty && CTX_wm_space_image(C)) {
uiLayout *row = uiLayoutRow(layout, true);
uiItemO(row, IFACE_("Save"), ICON_NONE, "image.save");
uiItemO(row, IFACE_("Discard"), ICON_NONE, "image.reload");