From: Jihoon Kim Date: Mon, 2 Apr 2018 10:01:39 +0000 (+0900) Subject: Fix defects detected by static analysis tool X-Git-Tag: submit/tizen/20180402.102536~1 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=68560991cffc25a11f7b1efa2e4491e55d0e18aa;p=platform%2Fcore%2Fuifw%2Finputdelegator.git Fix defects detected by static analysis tool Change-Id: Ia800fe14ca76dd427e3cd64d77b224c23d613ad4 Signed-off-by: Jihoon Kim --- diff --git a/src/w-input-stt-voice.cpp b/src/w-input-stt-voice.cpp index 2aac43a..815ef56 100755 --- a/src/w-input-stt-voice.cpp +++ b/src/w-input-stt-voice.cpp @@ -566,7 +566,10 @@ static Eina_Bool _power_delayed_unlock(void *data){ PRINTFUNC(DLOG_DEBUG, "POWER Unlock"); VoiceData *voicedata = (VoiceData *) data; - device_power_release_lock(POWER_LOCK_DISPLAY); + int ret = device_power_release_lock(POWER_LOCK_DISPLAY); + if (ret != DEVICE_ERROR_NONE) + LOGW("Failed to release power(Display) (%d)", ret); + voicedata->power_unlock_timer = NULL; return ECORE_CALLBACK_CANCEL; @@ -575,7 +578,9 @@ static Eina_Bool _power_delayed_unlock(void *data){ void powerUnlock() { PRINTFUNC(DLOG_DEBUG, "POWER Unlock directly."); - device_power_release_lock(POWER_LOCK_DISPLAY); + int ret = device_power_release_lock(POWER_LOCK_DISPLAY); + if (ret != DEVICE_ERROR_NONE) + LOGW("Failed to release power(Display) (%d)", ret); } void powerLock(void *data, bool enable)