(fix) fixed handling of exdates and proper intersection for fbinfo (fixes #4051)

This commit is contained in:
Ludovic Marcotte
2017-03-03 14:14:16 -05:00
parent 2f56bb43be
commit 84deb2fe45
3 changed files with 10 additions and 9 deletions
@@ -1299,17 +1299,13 @@ firstInstanceCalendarDateRange: (NGCalendarDateRange *) fir
{
NSMutableArray *ma;
NSDictionary *row;
NSCalendarDate *rangeEndDate;
unsigned int count, max;
max = [_records count];
ma = [NSMutableArray arrayWithCapacity: max];
// Adjust the range so it ends at midnight. This is necessary when calculating
// recurrences of all-day events.
rangeEndDate = [[_r endDate] dateByAddingYears:0 months:0 days:0 hours:0 minutes:0 seconds:1];
_r = [NGCalendarDateRange calendarDateRangeWithStartDate: [_r startDate]
endDate: rangeEndDate];
endDate: [_r endDate]];
for (count = 0; count < max; count++)
{