projects
/
platform
/
core
/
uifw
/
libtdm.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
1f03935
)
tdm_helper: set up error handling when dump png
57/219957/1
author
Changyeon Lee
<cyeon.lee@samsung.com>
Thu, 12 Dec 2019 04:25:25 +0000
(13:25 +0900)
committer
Changyeon Lee
<cyeon.lee@samsung.com>
Thu, 12 Dec 2019 04:58:00 +0000
(13:58 +0900)
Change-Id: Id3c9d591057b3ab73358ab810fb551452ee7cba0
src/tdm_helper.c
patch
|
blob
|
history
diff --git
a/src/tdm_helper.c
b/src/tdm_helper.c
index
804a112
..
08477f1
100644
(file)
--- a/
src/tdm_helper.c
+++ b/
src/tdm_helper.c
@@
-136,6
+136,13
@@
_tdm_helper_dump_png(const char *file, const void *data, int width,
return;
}
+ if (setjmp(png_jmpbuf(pPngStruct))) {
+ /* if png has problem of writing the file, we get here */
+ png_destroy_write_struct(&pPngStruct, &pPngInfo);
+ fclose(fp);
+ return;
+ }
+
png_init_io(pPngStruct, fp);
png_set_IHDR(pPngStruct,
pPngInfo,