diff options
author | Jiwoong Im <jiwoong.im@samsung.com> | 2016-05-16 11:49:00 +0900 |
---|---|---|
committer | Jiwoong Im <jiwoong.im@samsung.com> | 2016-05-16 11:51:23 +0900 |
commit | 9b945eaec3cc6da144ae1416ce3f6bf5c1ff90d8 (patch) | |
tree | 9775ee366a17e38e944e259c0ce8e426f53f1c8d /src | |
parent | 042d51f6ccead520fee3616ec959377cce995153 (diff) | |
download | alarm-manager-9b945eaec3cc6da144ae1416ce3f6bf5c1ff90d8.tar.gz alarm-manager-9b945eaec3cc6da144ae1416ce3f6bf5c1ff90d8.tar.bz2 alarm-manager-9b945eaec3cc6da144ae1416ce3f6bf5c1ff90d8.zip |
Fix some returns in alarm set/get apisubmit/tizen/20160516.093613accepted/tizen/wearable/20160517.032536accepted/tizen/tv/20160517.032525accepted/tizen/mobile/20160517.032550accepted/tizen/ivi/20160517.032508accepted/tizen/common/20160517.173921
Change-Id: I40101a3bdd1071765290172d916cd55abb7152d5
Signed-off-by: Jiwoong Im <jiwoong.im@samsung.com>
Diffstat (limited to 'src')
-rw-r--r-- | src/alarm-lib.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/alarm-lib.c b/src/alarm-lib.c index 3f3a0a3..9aaa838 100644 --- a/src/alarm-lib.c +++ b/src/alarm-lib.c @@ -1631,6 +1631,9 @@ EXPORT_API int alarmmgr_set_global(const alarm_id_t alarm_id, int error_code; ALARM_MGR_LOG_PRINT("[alarm-lib]:alarmmgr_set_global() is called."); + if (__sub_init() < 0) + return ERR_ALARM_SYSTEM_FAIL; + if (!_send_alarm_set_global(alarm_context, alarm_id, global, &error_code)) return error_code; @@ -1644,6 +1647,9 @@ EXPORT_API int alarmmgr_get_global(const alarm_id_t alarm_id, bool _global; int error_code; + if (__sub_init() < 0) + return ERR_ALARM_SYSTEM_FAIL; + if (global == NULL) return ERR_ALARM_INVALID_PARAM; |