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:
-rw-r--r--source/blender/imbuf/intern/bmp.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/source/blender/imbuf/intern/bmp.c b/source/blender/imbuf/intern/bmp.c
index 7f7e30923b7..6817040faa8 100644
--- a/source/blender/imbuf/intern/bmp.c
+++ b/source/blender/imbuf/intern/bmp.c
@@ -243,5 +243,9 @@ short imb_savebmp(struct ImBuf *ibuf, int outfile, int flags) {
/* add padding here */
for (t=0;t<extrabytes;t++) if (putc(0,ofile) == EOF) return 0;
}
+ if (ofile) {
+ fflush(ofile);
+ fclose(ofile);
+ }
return 1;
}