fixed svace isues
[platform/adaptation/ap_samsung/libomxil-e3250-v4l2.git] / openmax / component / video / enc / h264 / Exynos_OMX_H264enc.c
index 41cd3f2..f4f7808 100755 (executable)
@@ -1080,6 +1080,16 @@ EXIT:
     FunctionOut();
 
     return ret;
+
+ALLOC_FAILED:
+    for (i = 0; i < MFC_OUTPUT_BUFFER_NUM_MAX; i++) {
+        if (pVideoEnc->pMFCEncOutputBuffer[i])
+            Exynos_OSAL_Free(pVideoEnc->pMFCEncOutputBuffer[i]);
+    }
+    Exynos_OSAL_Log(EXYNOS_LOG_ERROR, "Failed to allocate buffers");
+    FunctionOut();
+
+    return ret;
 }
 
 OMX_ERRORTYPE Exynos_H264Enc_GetParameter(