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:
authorBastien Montagne <montagne29@wanadoo.fr>2018-07-11 15:32:43 +0300
committerBastien Montagne <montagne29@wanadoo.fr>2018-07-11 15:32:43 +0300
commit08274433e1bd9db5a2a27e5d2f8862e9cc3f27f0 (patch)
tree981608b978e17c316d5db766e26c358c43d4398b /source/blender
parent59b4c675361b54b32b6238855fe4a82117cc48c7 (diff)
Fix T55912: saving Viewer Node image error.
Images from viewer node needs the lock parameter...
Diffstat (limited to 'source/blender')
-rw-r--r--source/blender/makesrna/intern/rna_image_api.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/source/blender/makesrna/intern/rna_image_api.c b/source/blender/makesrna/intern/rna_image_api.c
index 916ba660249..b6ba06a84d5 100644
--- a/source/blender/makesrna/intern/rna_image_api.c
+++ b/source/blender/makesrna/intern/rna_image_api.c
@@ -118,7 +118,9 @@ static void rna_Image_save_render(Image *image, bContext *C, ReportList *reports
static void rna_Image_save(Image *image, Main *bmain, bContext *C, ReportList *reports)
{
- ImBuf *ibuf = BKE_image_acquire_ibuf(image, NULL, NULL);
+ void *lock;
+
+ ImBuf *ibuf = BKE_image_acquire_ibuf(image, NULL, &lock);
if (ibuf) {
char filename[FILE_MAX];
BLI_strncpy(filename, image->name, sizeof(filename));
@@ -145,7 +147,7 @@ static void rna_Image_save(Image *image, Main *bmain, bContext *C, ReportList *r
BKE_reportf(reports, RPT_ERROR, "Image '%s' does not have any image data", image->id.name + 2);
}
- BKE_image_release_ibuf(image, ibuf, NULL);
+ BKE_image_release_ibuf(image, ibuf, &lock);
WM_event_add_notifier(C, NC_IMAGE | NA_EDITED, image);
}