From: Suyeon Hwang Date: Fri, 26 Feb 2021 04:39:33 +0000 (+0900) Subject: Fix state check code X-Git-Tag: submit/tizen/20210226.051815~1 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=refs%2Fchanges%2F06%2F254306%2F1;p=platform%2Fcore%2Fuifw%2Ftts.git Fix state check code Current state check code just checks current state is ready or not. However, if state is not ready, client is still connected to server, because playing or processing state also means the connection is still on. This patch changes the state check code to exact way. Change-Id: Idb3be9f1b042c01dbd7c2e5f208866d70d8a25a0 Signed-off-by: Suyeon Hwang --- diff --git a/client/tts_core.c b/client/tts_core.c index 575e4b7..7dcac7f 100644 --- a/client/tts_core.c +++ b/client/tts_core.c @@ -834,8 +834,8 @@ int tts_core_receive_hello(int uid, int ret, int credential_needed) return TTS_ERROR_OPERATION_FAILED; } - if (TTS_STATE_READY == client->current_state) { - SLOG(LOG_INFO, TAG_TTSC, "[INFO] tts client is already READY"); + if (TTS_STATE_CREATED != client->current_state) { + SLOG(LOG_INFO, TAG_TTSC, "[INFO] tts client is already prepared"); return TTS_ERROR_NONE; }