summaryrefslogtreecommitdiff
path: root/libcsc
diff options
context:
space:
mode:
authorSejun Park <sejun79.park@samsung.com>2018-02-14 11:50:50 +0900
committerSejun Park <sejun79.park@samsung.com>2018-02-14 11:50:50 +0900
commit682763663709dac5efcff1c9772647654172e5a5 (patch)
tree85efa0444eb459e873dc9fdf0b255cbd00bc53af /libcsc
parentdbdcb66ed63a6f770944c09afa455bb82fc1393e (diff)
downloadlibexynos-common-682763663709dac5efcff1c9772647654172e5a5.tar.gz
libexynos-common-682763663709dac5efcff1c9772647654172e5a5.tar.bz2
libexynos-common-682763663709dac5efcff1c9772647654172e5a5.zip
Change-Id: Ia75080d7a040bc646693224978ce57bdf586bd8f
Diffstat (limited to 'libcsc')
-rwxr-xr-xlibcsc/csc.c17
1 files changed, 13 insertions, 4 deletions
diff --git a/libcsc/csc.c b/libcsc/csc.c
index d90968e..39e4a95 100755
--- a/libcsc/csc.c
+++ b/libcsc/csc.c
@@ -745,6 +745,7 @@ static CSC_ERRORCODE csc_init_hw(
ALOGE("%s:: CSC_METHOD_HW can't open HW", __func__);
free(csc_handle);
csc_handle = NULL;
+ ret = CSC_ErrorNotInit;
}
}
if (csc_handle)
@@ -1260,8 +1261,12 @@ CSC_ERRORCODE csc_convert(
return CSC_ErrorNotInit;
if ((csc_handle->csc_method == CSC_METHOD_HW) &&
- (csc_handle->csc_hw_handle == NULL))
- csc_init_hw(handle);
+ (csc_handle->csc_hw_handle == NULL)) {
+ ret = csc_init_hw(handle);
+
+ if (ret != CSC_ErrorNone)
+ return ret;
+ }
csc_set_format(csc_handle);
csc_set_buffer(csc_handle);
@@ -1284,8 +1289,12 @@ CSC_ERRORCODE csc_convert_with_rotation(
return CSC_ErrorNotInit;
if ((csc_handle->csc_method == CSC_METHOD_HW) &&
- (csc_handle->csc_hw_handle == NULL))
- csc_init_hw(handle);
+ (csc_handle->csc_hw_handle == NULL)) {
+ ret = csc_init_hw(handle);
+
+ if (ret != CSC_ErrorNone)
+ return ret;
+ }
csc_set_format(csc_handle);
csc_set_buffer(csc_handle);