fixed svace issue
[platform/adaptation/ap_samsung/libomxil-e3250-v4l2.git] / exynos / libcsc / csc.c
index a55a011..39c0e0e 100644 (file)
@@ -439,6 +439,7 @@ static CSC_ERRORCODE csc_init_hw(
             ALOGE("%s:: CSC_METHOD_HW can't open HW", __func__);
             free(csc_handle);
             csc_handle = NULL;
+            return CSC_ErrorNotInit;
         }
     }
 
@@ -804,7 +805,10 @@ CSC_ERRORCODE csc_convert(
 
     if ((csc_handle->csc_method == CSC_METHOD_HW) &&
         (csc_handle->csc_hw_handle == NULL))
-        csc_init_hw(handle);
+        ret = csc_init_hw(handle);
+
+    if (ret != CSC_ErrorNone)
+        return ret;
 
     csc_set_format(csc_handle);
     csc_set_buffer(csc_handle);