summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJi Yong Min <jiyong.min@samsung.com>2015-12-31 11:13:38 +0900
committerJi Yong Min <jiyong.min@samsung.com>2015-12-31 11:15:08 +0900
commit0b93b1b8120f67ff36262e6f2b9a75f7cf1670e3 (patch)
treebc6138d9eac5e2f1f331a9903bb21f46d3f67e52
parent292143cf12c6261504527db7022f365bd16f1a1c (diff)
downloadlibmedia-thumbnail-accepted/tizen/mobile/20151231.073814.tar.gz
libmedia-thumbnail-accepted/tizen/mobile/20151231.073814.tar.bz2
libmedia-thumbnail-accepted/tizen/mobile/20151231.073814.zip
Change-Id: Id4c6844de04c8c976d46f4d0d0a8147ce3d8a973 Signed-off-by: Jiyong Min <jiyong.min@samsung.com>
-rw-r--r--packaging/libmedia-thumbnail.spec2
-rwxr-xr-xsrc/codec/IfegDecodeAGIF.c2
-rwxr-xr-xsrc/codec/img-codec.c7
3 files changed, 5 insertions, 6 deletions
diff --git a/packaging/libmedia-thumbnail.spec b/packaging/libmedia-thumbnail.spec
index e088f94..a435c73 100644
--- a/packaging/libmedia-thumbnail.spec
+++ b/packaging/libmedia-thumbnail.spec
@@ -1,6 +1,6 @@
Name: libmedia-thumbnail
Summary: Media thumbnail service library for multimedia applications
-Version: 0.1.87
+Version: 0.1.88
Release: 0
Group: Multimedia/Libraries
License: Apache-2.0 and public domain
diff --git a/src/codec/IfegDecodeAGIF.c b/src/codec/IfegDecodeAGIF.c
index db69692..b6a08f2 100755
--- a/src/codec/IfegDecodeAGIF.c
+++ b/src/codec/IfegDecodeAGIF.c
@@ -111,8 +111,6 @@ AGifFrameInfo *FastImgCreateAGIFFrameData(unsigned int width, unsigned int heigh
if (transparent == 1 && backcolor_index == transIndex) {
image_backcolor = ui_backcolor;
- } else if (transparent == 1 && backcolor_index != transIndex) {
- image_backcolor = backcolor_parsing;
} else {
image_backcolor = backcolor_parsing;
}
diff --git a/src/codec/img-codec.c b/src/codec/img-codec.c
index 1887e47..e37ab8b 100755
--- a/src/codec/img-codec.c
+++ b/src/codec/img-codec.c
@@ -151,8 +151,8 @@ AGifFrameInfo *ImgCreateAGIFFrame(const char *szFileName, unsigned int width, un
DrmGetFileAttributes(szFileName, &fileAttrib);
- if (fileAttrib.fileSize == 0) {
- thumb_err("Zero File Size");
+ if (fileAttrib.fileSize <= 0) {
+ thumb_err("Zero or below Zero File Size");
DrmCloseFile(hFile);
return NULL;
}
@@ -161,7 +161,8 @@ AGifFrameInfo *ImgCreateAGIFFrame(const char *szFileName, unsigned int width, un
/* A size of allocated memory - w * h *2 means RGB565 and 4096 means the max of header length */
// mem_alloc_size = width * height * 2 + MAX_GIF_HEADER_SIZE;
mem_alloc_size = cFileSize;
- if ((pEncodedData = (unsigned char *)malloc(mem_alloc_size)) == NULL) {
+ pEncodedData = (unsigned char *)malloc(mem_alloc_size);
+ if (pEncodedData == NULL) {
thumb_err("Memory Allocation to pEncodedData failed");
DrmCloseFile(hFile);
return NULL;