errorCode = calendar_vcalendar_parse_to_calendar(reinterpret_cast<char*>(const_cast<byte*>(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<ArrayList, AllElementsDeleter> pList(new (std::nothrow) ArrayList());
errorCode = calendar_vcalendar_parse_to_calendar(reinterpret_cast<char*>(const_cast<byte*>(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<ArrayList, AllElementsDeleter> pList(new (std::nothrow) ArrayList());