From 74dd73c38e0f0ecc34c80a215c117ea6a01d7366 Mon Sep 17 00:00:00 2001 From: Jiwoong Im Date: Fri, 14 Apr 2017 11:35:02 +0900 Subject: [PATCH] Send launch request asynchronously in alarm expired - If target application is in ANR status, appsvc_usr_run_service api can be blocked. To solve this, use async api in sending launch request. - Requires: [aul-1] https://review.tizen.org/gerrit/#/c/124571/ Change-Id: I65af5d9ba00bf378296899db2d6ff130e482fe18 Signed-off-by: Jiwoong Im --- alarm-manager.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/alarm-manager.c b/alarm-manager.c index 3e162c7..a5caf4b 100644 --- a/alarm-manager.c +++ b/alarm-manager.c @@ -32,6 +32,7 @@ #include #include +#include #include #include #include @@ -1737,7 +1738,7 @@ static void __alarm_expired() if (result < 0) { /* before 2.4 */ - if (appsvc_usr_run_service(b, 0, NULL, NULL, __alarm_info->uid) < 0) + if (aul_svc_run_service_async_for_uid(b, 0, NULL, NULL, __alarm_info->uid) < 0) ALARM_MGR_EXCEPTION_PRINT("Unable to run app svc\n"); else ALARM_MGR_LOG_PRINT("Successfuly run app svc\n"); @@ -1753,10 +1754,10 @@ static void __alarm_expired() ALARM_MGR_EXCEPTION_PRINT("Fail to get login user\n"); ret = -1; } else { - ret = appsvc_usr_run_service(b, 0, NULL, NULL, target_uid); + ret = aul_svc_run_service_async_for_uid(b, 0, NULL, NULL, target_uid); } } else { - ret = appsvc_usr_run_service(b, 0, NULL, NULL, __alarm_info->uid); + ret = aul_svc_run_service_async_for_uid(b, 0, NULL, NULL, __alarm_info->uid); } if (ret < 0) { -- 2.7.4