From 99a4c991ee1b866f61fb384eef407885bd628a81 Mon Sep 17 00:00:00 2001 From: "hs321.lee" Date: Thu, 25 Jul 2013 11:41:12 +0900 Subject: [PATCH] Add codes handling the CALENDAR_ERROR_NO_DATA exeption Change-Id: I2e2ac879392684dd09b22bffe6adfc7beb143f68 Signed-off-by: hs321.lee --- src/FScl_CalendarbookImpl.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/FScl_CalendarbookImpl.cpp b/src/FScl_CalendarbookImpl.cpp index 939c226..834e56f 100644 --- a/src/FScl_CalendarbookImpl.cpp +++ b/src/FScl_CalendarbookImpl.cpp @@ -1640,7 +1640,7 @@ _CalendarbookImpl::ParseEventsFromVcalendarN(const String& vCalFilePath) errorCode = calendar_vcalendar_parse_to_calendar(reinterpret_cast(const_cast(pBuffer->GetPointer())), &calendarListHandle); SysTryReturn(NID_SCL, errorCode != CALENDAR_ERROR_OUT_OF_MEMORY, null, E_OUT_OF_MEMORY, "[E_OUT_OF_MEMORY] Memory allocation failed."); SysTryReturn(NID_SCL, errorCode != CALENDAR_ERROR_INVALID_PARAMETER, null, E_INVALID_ARG, "[E_INVALID_ARG] Invalid argument is used. The vCal file is invalid."); - SysTryReturn(NID_SCL, errorCode == CALENDAR_ERROR_NONE, null, E_SYSTEM, "[E_SYSTEM] A system error has been occurred."); + SysTryReturn(NID_SCL, errorCode == CALENDAR_ERROR_NONE || errorCode == CALENDAR_ERROR_NO_DATA, null, E_SYSTEM, "[E_SYSTEM] A system error has been occurred."); _CalendarList calendarList(calendarListHandle); std::unique_ptr pList(new (std::nothrow) ArrayList()); @@ -1737,7 +1737,7 @@ _CalendarbookImpl::ParseTodosFromVcalendarN(const String& vCalFilePath) errorCode = calendar_vcalendar_parse_to_calendar(reinterpret_cast(const_cast(pBuffer->GetPointer())), &calendarListHandle); SysTryReturn(NID_SCL, errorCode != CALENDAR_ERROR_OUT_OF_MEMORY, null, E_OUT_OF_MEMORY, "[E_OUT_OF_MEMORY] Memory allocation failed."); SysTryReturn(NID_SCL, errorCode != CALENDAR_ERROR_INVALID_PARAMETER, null, E_INVALID_ARG, "[E_INVALID_ARG] Invalid argument is used. The vCal file is invalid."); - SysTryReturn(NID_SCL, errorCode == CALENDAR_ERROR_NONE, null, E_SYSTEM, "[E_SYSTEM] A system error has been occurred."); + SysTryReturn(NID_SCL, errorCode == CALENDAR_ERROR_NONE || errorCode == CALENDAR_ERROR_NO_DATA, null, E_SYSTEM, "[E_SYSTEM] A system error has been occurred."); _CalendarList calendarList(calendarListHandle); std::unique_ptr pList(new (std::nothrow) ArrayList()); -- 2.7.4