[GH-ISSUE #25] Events without DTEND lead to exception #916

Closed
opened 2026-03-13 23:19:47 +03:00 by kerem · 1 comment
Owner

Originally created by @aluxnimm on GitHub (Mar 26, 2015).
Original GitHub issue: https://github.com/aluxnimm/outlookcaldavsynchronizer/issues/25

Originally assigned to: @aluxnimm on GitHub.

ERROR 2015-03-25 23:34:55,008 [VSTA_Main] neric.Synchronization.States.StateBase6 . LogException - Exception occured: System.NullReferenceException: Der Objektverweis wurde nicht auf eine Objektinstanz festgelegt. bei CalDavSynchronizer.Implementation.AppointmentEventEntityMapper.Map2To1(IEvent source, AppointmentItem target) in e:\CalDavSynchronizer\outlookcaldavsynchronizer-code-38b47cb3c0654370908c66bc25d72204d240cdc3\CalDavSynchronizer\Implementation\EntityMapper.cs:Zeile 370. bei CalDavSynchronizer.Generic.Synchronization.States.CreateInA6.b__0(TAtypeEntity a) in e:\CalDavSynchronizer\outlookcaldavsynchronizer-code-38b47cb3c0654370908c66bc25d72204d240cdc3\CalDavSynchronizer\Generic\Synchronization\States\CreateInA.cs:Zeile 68.
bei CalDavSynchronizer.Implementation.OutlookAppoointmentRepository.Create(Func2 entityInitializer) in e:\CalDavSynchronizer\outlookcaldavsynchronizer-code-38b47cb3c0654370908c66bc25d72204d240cdc3\CalDavSynchronizer\Implementation\OutlookAppoointmentRepository.cs:Zeile 113. bei CalDavSynchronizer.Generic.Synchronization.States.CreateInA6.PerformSyncActionNoThrow() in e:\CalDavSynchronizer\outlookcaldavsynchronizer-code-38b47cb3c0654370908c66bc25d72204d240cdc3\CalDavSynchronizer\Generic\Synchronization\States\CreateInA.cs:Zeile 68.

According to the RFC:
For cases where a "VEVENT" calendar component specifies a "DTSTART"
property with a DATE data type but no "DTEND" property, the events
non-inclusive end is the end of the calendar date specified by the
"DTSTART" property. For cases where a "VEVENT" calendar component
specifies a "DTSTART" property with a DATE-TIME data type but no
"DTEND" property, the event ends on the same calendar date and time
of day specified by the "DTSTART" property.

So in the EntityMapper, line 370
target.EndUTC = source.DTEnd.UTC;
should be changed to the start date if source.DTEnd==null

Original comment by: aluxnimm

Original Ticket: outlookcaldavsynchronizer/15

Originally created by @aluxnimm on GitHub (Mar 26, 2015). Original GitHub issue: https://github.com/aluxnimm/outlookcaldavsynchronizer/issues/25 Originally assigned to: @aluxnimm on GitHub. ERROR 2015-03-25 23:34:55,008 [VSTA_Main] neric.Synchronization.States.StateBase`6 . LogException - Exception occured: System.NullReferenceException: Der Objektverweis wurde nicht auf eine Objektinstanz festgelegt. bei CalDavSynchronizer.Implementation.AppointmentEventEntityMapper.Map2To1(IEvent source, AppointmentItem target) in e:\CalDavSynchronizer\outlookcaldavsynchronizer-code-38b47cb3c0654370908c66bc25d72204d240cdc3\CalDavSynchronizer\Implementation\EntityMapper.cs:Zeile 370. bei CalDavSynchronizer.Generic.Synchronization.States.CreateInA`6.<PerformSyncActionNoThrow>b__0(TAtypeEntity a) in e:\CalDavSynchronizer\outlookcaldavsynchronizer-code-38b47cb3c0654370908c66bc25d72204d240cdc3\CalDavSynchronizer\Generic\Synchronization\States\CreateInA.cs:Zeile 68. bei CalDavSynchronizer.Implementation.OutlookAppoointmentRepository.Create(Func`2 entityInitializer) in e:\CalDavSynchronizer\outlookcaldavsynchronizer-code-38b47cb3c0654370908c66bc25d72204d240cdc3\CalDavSynchronizer\Implementation\OutlookAppoointmentRepository.cs:Zeile 113. bei CalDavSynchronizer.Generic.Synchronization.States.CreateInA`6.PerformSyncActionNoThrow() in e:\CalDavSynchronizer\outlookcaldavsynchronizer-code-38b47cb3c0654370908c66bc25d72204d240cdc3\CalDavSynchronizer\Generic\Synchronization\States\CreateInA.cs:Zeile 68. According to the RFC: For cases where a "VEVENT" calendar component specifies a "DTSTART" property with a DATE data type but no "DTEND" property, the events non-inclusive end is the end of the calendar date specified by the "DTSTART" property. For cases where a "VEVENT" calendar component specifies a "DTSTART" property with a DATE-TIME data type but no "DTEND" property, the event ends on the same calendar date and time of day specified by the "DTSTART" property. So in the EntityMapper, line 370 target.EndUTC = source.DTEnd.UTC; should be changed to the start date if source.DTEnd==null Original comment by: aluxnimm Original Ticket: [outlookcaldavsynchronizer/15](https://sourceforge.net/p/outlookcaldavsynchronizer/15)
Author
Owner

@aluxnimm commented on GitHub (Mar 26, 2015):

  • labels: --> solved
  • status: open --> closed

Original comment by: nertsch

<!-- gh-comment-id:126312492 --> @aluxnimm commented on GitHub (Mar 26, 2015): - **labels**: --> solved - **status**: open --> closed Original comment by: nertsch
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/outlookcaldavsynchronizer#916
No description provided.