if (handle != NULL) {
memset(handle, 0 , sizeof(mediacodec_s));
} else {
- LOGE("MEDIACODEC_ERROR_OUT_OF_MEMORY(0x%08x)", MEDIACODEC_ERROR_OUT_OF_MEMORY);
+ LOGE("MEDIACODEC_ERROR_OUT_OF_MEMORY(0x%08x)", MEDIACODEC_ERROR_OUT_OF_MEMORY); //LCOV_EXCL_LINE
return MEDIACODEC_ERROR_OUT_OF_MEMORY;
}
ret = mc_create(&handle->mc_handle);
if (ret != MEDIACODEC_ERROR_NONE) {
- LOGE("MEDIACODEC_ERROR_INVALID_OPERATION(0x%08x)", MEDIACODEC_ERROR_INVALID_OPERATION);
+ LOGE("MEDIACODEC_ERROR_INVALID_OPERATION(0x%08x)", MEDIACODEC_ERROR_INVALID_OPERATION); //LCOV_EXCL_LINE
handle->state = MEDIACODEC_STATE_NONE;
g_free(handle->mc_handle);
g_free(handle);
int ret = mc_destroy(handle->mc_handle);
if (ret != MEDIACODEC_ERROR_NONE) {
- LOGD("MEDIACODEC_ERROR_INVALID_OPERATION(0x%08x)", MEDIACODEC_ERROR_INVALID_OPERATION);
+ LOGD("MEDIACODEC_ERROR_INVALID_OPERATION(0x%08x)", MEDIACODEC_ERROR_INVALID_OPERATION); //LCOV_EXCL_LINE
return MEDIACODEC_ERROR_INVALID_OPERATION;
} else {
g_mutex_lock(&mediacodec_handles_lock);
if (mc_handle->is_hw && mc_handle->is_video) {
if (handle->codec_resource) {
- LOGE("Codec resource is tried to be acquired twice\n");
+ LOGE("Codec resource is tried to be acquired twice\n"); //LCOV_EXCL_LINE
return MC_INTERNAL_ERROR;
}
* mm_resource_manager_get_res_type_volume() can be used.
* Additional info can be found in doxygen comments of mm_resource_manager.h
*/
+//LCOV_EXCL_START
rm_ret = mm_resource_manager_mark_for_acquire(resource_manager,
mc_handle->is_encoder ?
MM_RESOURCE_MANAGER_RES_TYPE_VIDEO_ENCODER :
LOGE("Failed to commit resource manager : %x", rm_ret);
return MEDIACODEC_ERROR_INTERNAL;
}
-
handle->codec_resource = resource;
+//LCOV_EXCL_STOP
}
int ret = mc_prepare(handle->mc_handle);
return 1;
}
-
+//LCOV_EXCL_START
static int __mediacodec_resource_release_cb(mm_resource_manager_h rm,
mm_resource_manager_res_h resource_h, void *user_data)
{
return FALSE;
}
+//LCOV_EXCL_STOP
static void __mediacodec_init_lib()
{
if (MM_RESOURCE_MANAGER_ERROR_NONE != mm_resource_manager_create(MM_RESOURCE_MANAGER_APP_CLASS_MEDIA,
__mediacodec_resource_release_cb, NULL, &resource_manager)) {
- LOGE("Failed to initialize resource manager");
+ LOGE("Failed to initialize resource manager"); //LCOV_EXCL_LINE
g_ptr_array_unref(mediacodec_handles);
}
}