From: Suyeon Hwang Date: Thu, 23 Sep 2021 11:47:12 +0000 (+0900) Subject: Handle already_initialize error properly not ignored X-Git-Tag: submit/fixVD/20210927.111930~4^2 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=97ac28920e0c1bb369aae08c73d72e7ac6cdc0c1;p=platform%2Fcore%2Fuifw%2Ftts.git Handle already_initialize error properly not ignored Change-Id: Ib42f2750757371c74df1463ac8ba6ed738dc0847 Signed-off-by: Suyeon Hwang --- diff --git a/client/tts_core.c b/client/tts_core.c index e2b07179..0afa2c05 100644 --- a/client/tts_core.c +++ b/client/tts_core.c @@ -1016,15 +1016,15 @@ int tts_core_receive_hello(int uid, int ret, int credential_needed) tts_core_notify_error_async(client, ret, -1, NULL); return TTS_ERROR_OPERATION_FAILED; - } else if (TTS_ERROR_NONE != ret) { - SLOG(LOG_WARN, TAG_TTSC, "[WARNING] Fail to connection. Retry to connect : %s", tts_core_covert_error_code(ret)); - return TTS_ERROR_OPERATION_FAILED; - } else { + } else if (TTS_ERROR_ALREADY_INITIALIZED == ret) { /* success to connect tts-daemon */ if (TTS_CREDENTIAL_NEEDED_ALREADY_INITIALIZED != credential_needed) { client->credential_needed = credential_needed; SLOG(LOG_ERROR, TAG_TTSC, "Supported options : credential(%d)", credential_needed); } + } else if (TTS_ERROR_NONE != ret) { + SLOG(LOG_WARN, TAG_TTSC, "[WARNING] Fail to connection. Retry to connect : %s", tts_core_covert_error_code(ret)); + return TTS_ERROR_OPERATION_FAILED; } tts_core_notify_state_changed_async(client, TTS_STATE_READY);