From: sooyeon.kim Date: Tue, 7 Mar 2017 12:00:16 +0000 (+0900) Subject: Fix dangling pointer X-Git-Tag: accepted/tizen/unified/20170406.054241^0 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=refs%2Fchanges%2F91%2F117991%2F1;p=platform%2Fcore%2Fuifw%2Ftts.git Fix dangling pointer Change-Id: I30485e11e22ea7dee777adb0cf5306379127e791 Signed-off-by: sooyeon.kim (cherry picked from commit ae6ebaaacbe99a3412703836c2563eb8182d9e2e) --- diff --git a/common/tts_config_mgr.c b/common/tts_config_mgr.c index 717ff9a..8ad002b 100644 --- a/common/tts_config_mgr.c +++ b/common/tts_config_mgr.c @@ -1122,6 +1122,7 @@ int tts_config_mgr_initialize(int uid) __tts_config_release_client(uid); __tts_config_release_engine(); tts_parser_unload_config(g_config_info); + g_config_info = NULL; return TTS_CONFIG_ERROR_ENGINE_NOT_FOUND; } @@ -1138,6 +1139,7 @@ int tts_config_mgr_initialize(int uid) __tts_config_release_client(uid); __tts_config_release_engine(); tts_parser_unload_config(g_config_info); + g_config_info = NULL; return TTS_CONFIG_ERROR_OPERATION_FAILED; } @@ -1156,6 +1158,7 @@ int tts_config_mgr_initialize(int uid) __tts_config_release_client(uid); __tts_config_release_engine(); tts_parser_unload_config(g_config_info); + g_config_info = NULL; return TTS_CONFIG_ERROR_OPERATION_FAILED; } } @@ -1178,6 +1181,7 @@ int tts_config_mgr_initialize(int uid) __tts_config_release_client(uid); __tts_config_release_engine(); tts_parser_unload_config(g_config_info); + g_config_info = NULL; return TTS_CONFIG_ERROR_OPERATION_FAILED; } @@ -1209,6 +1213,7 @@ int tts_config_mgr_finalize(int uid) __tts_config_release_engine(); tts_parser_unload_config(g_config_info); + g_config_info = NULL; __tts_config_mgr_unregister_engine_config_updated_event();