char* engine_appid = __get_engine_appid();
if (NULL == engine_appid) {
SLOG(LOG_ERROR, TAG_VCC, "[TIDL ERROR] Fail to get engine appid");
+ free(info);
return VC_ERROR_OUT_OF_MEMORY;
}
info->engine_appid = __get_engine_appid();
if (NULL == info->engine_appid) {
SLOG(LOG_ERROR, TAG_VCC, "[TIDL ERROR] Fail to get engine appid");
+ free(info);
return VC_ERROR_OUT_OF_MEMORY;
}
info->rpc_h = __create_rpc_port(pid, info->engine_appid);
if (NULL == info->rpc_h) {
SLOG(LOG_ERROR, TAG_VCC, "[TIDL ERROR] Fail to create proxy");
+ free(info->engine_appid);
free(info);
return VC_ERROR_OPERATION_FAILED;
}
ret = -1;
retry_count = 0;
while (0 != ret) {
+ pthread_mutex_lock(&g_w_init_mutex);
if (g_ask_to_cancel_preparing) {
SLOG(LOG_WARN, TAG_VCW, "[WARNING] Thread is canceled.");
ecore_main_loop_thread_safe_call_async(__vc_widget_delete_focus_event_handler, NULL);
g_w_prepare_thread = NULL;
+ pthread_mutex_unlock(&g_w_init_mutex);
return;
}
+ pthread_mutex_unlock(&g_w_init_mutex);
if (retry_count == 10) {
SLOG(LOG_ERROR, TAG_VCW, "[ERROR] Fail to connect daemon !!");