summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorsooyeon.kim <sooyeon.kim@samsung.com>2019-01-28 17:32:47 +0900
committersooyeon.kim <sooyeon.kim@samsung.com>2019-01-28 17:32:47 +0900
commitfb9c73980096c07f9ca28bdb1ccc078748355780 (patch)
treeec14da7c123aedb69562e933ddeb76aef70d4fe9
parentf0a11dcb2a0fbdc450f61c1365f067f9c44268fd (diff)
downloadstt-accepted/tizen_5.0_unified.tar.gz
stt-accepted/tizen_5.0_unified.tar.bz2
stt-accepted/tizen_5.0_unified.zip
Change-Id: I0595c67ab03efab92e29d93053c9af09a9bd2b8e Signed-off-by: sooyeon.kim <sooyeon.kim@samsung.com>
-rw-r--r--common/stt_engine.c2
-rw-r--r--server/sttd_server.c14
2 files changed, 15 insertions, 1 deletions
diff --git a/common/stt_engine.c b/common/stt_engine.c
index 14e6276..57944a2 100644
--- a/common/stt_engine.c
+++ b/common/stt_engine.c
@@ -557,7 +557,7 @@ int stt_engine_check_app_agreed(const char* appid, bool* is_agreed)
return 0;
}
- SLOG(LOG_INFO, stt_tag(), "[Engine Info] request to app agreed, appid(%s), is_agreed(%d)", appid, is_agreed);
+ SLOG(LOG_INFO, stt_tag(), "[Engine Info] request to app agreed, appid(%s), is_agreed(%d)", appid, *is_agreed);
int ret = g_engine->callback->check_app_agreed(appid, is_agreed);
if (0 != ret) {
diff --git a/server/sttd_server.c b/server/sttd_server.c
index f1bda74..ccaf29d 100644
--- a/server/sttd_server.c
+++ b/server/sttd_server.c
@@ -216,8 +216,11 @@ int __server_recognition_result_callback(stte_result_event_e event, const char*
/* Delete timer for processing time out */
if (NULL != g_processing_timer) {
+ ecore_thread_main_loop_begin();
+ SLOG(LOG_INFO, TAG_STTD, "[INFO] Delete g_processing_timer");
ecore_timer_del(g_processing_timer);
g_processing_timer = NULL;
+ ecore_thread_main_loop_end();
}
sttd_config_time_save();
@@ -272,8 +275,11 @@ int __server_recognition_result_callback(stte_result_event_e event, const char*
/* Delete timer for processing time out */
if (NULL != g_processing_timer) {
+ ecore_thread_main_loop_begin();
+ SLOG(LOG_INFO, TAG_STTD, "[INFO] Delete g_processing_timer");
ecore_timer_del(g_processing_timer);
g_processing_timer = NULL;
+ ecore_thread_main_loop_end();
}
sttd_config_time_reset();
@@ -707,6 +713,7 @@ int sttd_server_finalize(int uid)
if (APP_STATE_PROCESSING == state) {
if (NULL != g_processing_timer) {
+ SLOG(LOG_INFO, TAG_STTD, "[INFO] Delete g_processing_timer");
ecore_timer_del(g_processing_timer);
g_processing_timer = NULL;
}
@@ -1185,6 +1192,7 @@ int sttd_server_start(int uid, const char* lang, const char* recognition_type, i
}
if (NULL != g_processing_timer) {
+ SLOG(LOG_INFO, TAG_STTD, "[INFO] Delete g_processing_timer");
ecore_timer_del(g_processing_timer);
g_processing_timer = NULL;
}
@@ -1304,6 +1312,7 @@ int sttd_server_start(int uid, const char* lang, const char* recognition_type, i
Eina_Bool __time_out_for_processing(void *data)
{
if (NULL != g_processing_timer) {
+ SLOG(LOG_INFO, TAG_STTD, "[INFO] Delete g_processing_timer");
ecore_timer_del(g_processing_timer);
g_processing_timer = NULL;
}
@@ -1402,6 +1411,7 @@ int sttd_server_stop(int uid)
}
if (NULL != g_processing_timer) {
+ SLOG(LOG_INFO, TAG_STTD, "[INFO] Delete g_processing_timer");
ecore_timer_del(g_processing_timer);
g_processing_timer = NULL;
}
@@ -1447,6 +1457,7 @@ int sttd_server_stop(int uid)
}
free(sound);
+ SLOG(LOG_INFO, TAG_STTD, "[INFO] Add g_processing_timer");
g_processing_timer = ecore_timer_add(g_processing_timeout, __time_out_for_processing, NULL);
return STTD_RESULT_STATE_NOT_DONE;
@@ -1476,6 +1487,7 @@ int sttd_server_stop(int uid)
SLOG(LOG_INFO, TAG_STTD, "[Server SUCCESS] Stop recognition");
+ SLOG(LOG_INFO, TAG_STTD, "[INFO] Add g_processing_timer");
g_processing_timer = ecore_timer_add(g_processing_timeout, __time_out_for_processing, NULL);
return STTD_RESULT_STATE_DONE;
@@ -1509,6 +1521,7 @@ int sttd_server_cancel(int uid)
}
if (NULL != g_processing_timer) {
+ SLOG(LOG_INFO, TAG_STTD, "[INFO] Delete g_processing_timer");
ecore_timer_del(g_processing_timer);
g_processing_timer = NULL;
}
@@ -1682,6 +1695,7 @@ int sttd_server_cancel_file(int uid)
}
if (NULL != g_processing_timer) {
+ SLOG(LOG_INFO, TAG_STTD, "[INFO] Delete g_processing_timer");
ecore_timer_del(g_processing_timer);
g_processing_timer = NULL;
}