From: Wonnam Jang Date: Wed, 2 Nov 2016 02:39:38 +0000 (+0900) Subject: Fix PASSED_TO_PROC_AFTER_FREE issue X-Git-Tag: accepted/tizen/3.0/common/20161114.082353^0 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=c372049745c114f23364a784ab39b2fe090bb251;p=platform%2Fcore%2Fuifw%2Ftts.git Fix PASSED_TO_PROC_AFTER_FREE issue Change-Id: Ib3dfe120b409f5ffa30fe3ce610770e5f072c632 Signed-off-by: Wonnam Jang (cherry picked from commit 2815bf2a8af3181fe7dddd0188b9a718ad7eb756) --- diff --git a/common/tts_config_mgr.c b/common/tts_config_mgr.c index 3d7e18c..8259e2c 100755 --- a/common/tts_config_mgr.c +++ b/common/tts_config_mgr.c @@ -1503,12 +1503,11 @@ int tts_config_mgr_set_engine(const char* engine) g_config_info->engine_id = strdup(engine); - if (NULL != g_config_info->setting) { - free(g_config_info->setting); - g_config_info->setting = NULL; - } - if (NULL != engine_info->setting) { + if (NULL != g_config_info->setting) { + free(g_config_info->setting); + g_config_info->setting = NULL; + } g_config_info->setting = strdup(engine_info->setting); }