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
path: root/source
diff options
context:
space:
mode:
authorCampbell Barton <ideasman42@gmail.com>2020-11-13 03:34:53 +0300
committerJeroen Bakker <jeroen@blender.org>2020-12-02 10:33:56 +0300
commitd56111383a9907ebde9f5b05ce7c6e91dde4ebf0 (patch)
treeb24443f5c78c5e0e1b6a8b73189d8848fa6fdf18 /source
parent13b02a724f440cfab73a51ec2dfe709fd2eec2a1 (diff)
Fix memory leak writing PNG when opening the file fails
Diffstat (limited to 'source')
-rw-r--r--source/blender/imbuf/intern/png.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/source/blender/imbuf/intern/png.c b/source/blender/imbuf/intern/png.c
index 9e600f363c5..3ce575f5267 100644
--- a/source/blender/imbuf/intern/png.c
+++ b/source/blender/imbuf/intern/png.c
@@ -405,6 +405,7 @@ int imb_savepng(struct ImBuf *ibuf, const char *name, int flags)
if (pixels16) {
MEM_freeN(pixels16);
}
+ MEM_freeN(row_pointers);
printf("imb_savepng: Cannot open file for writing: '%s'\n", name);
return 0;
}