From 31f1c3b360cd2bc443ce378e33e6acec09d3cd62 Mon Sep 17 00:00:00 2001 From: david_kim31 Date: Thu, 4 Apr 2013 11:38:31 +0900 Subject: [PATCH] Add null pointer check Change-Id: Ie75cc997e4636de4767c5ad37242bad0ebb56729 Signed-off-by: david_kim31 --- src/system/FSys_AlarmManager.cpp | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/src/system/FSys_AlarmManager.cpp b/src/system/FSys_AlarmManager.cpp index 9aa022c..11d154a 100644 --- a/src/system/FSys_AlarmManager.cpp +++ b/src/system/FSys_AlarmManager.cpp @@ -91,7 +91,6 @@ _AlarmManager::ReserveAlarm(Tizen::Base::String appId, Tizen::Base::DateTime sta { int reservedAlarmId = -1; result r = E_SUCCESS; - int ret = 0; service_h service; @@ -491,14 +490,22 @@ _AlarmManager::OnAlarmExpired(int alarmId) SysLog(NID_SYS, "Next time is greater than end time."); RemoveAlarmList(alarmId); pValueEnum->Reset(); - pAlarmImpl->__alarmId.value = 0; + + if(pAlarmImpl != null) + { + pAlarmImpl->__alarmId.value = 0; + } } } } else if (pPeriod->ToInt() == 0) { RemoveAlarmList(alarmId); - pAlarmImpl->__alarmId.value = 0; + + if(pAlarmImpl != null) + { + pAlarmImpl->__alarmId.value = 0; + } } else { -- 2.7.4