Skip to content

Commit

Permalink
fix(calendar): fix monthly computation with month day mask
Browse files Browse the repository at this point in the history
Fixes #4915
  • Loading branch information
cgx committed Dec 24, 2019
1 parent d6d33f9 commit aaaa16e
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions SOPE/NGCards/iCalMonthlyRecurrenceCalculator.m
Expand Up @@ -99,12 +99,12 @@ static BOOL NGMonthDaySet_fillWithByMonthDay (NGMonthDaySet *positiveDaySet,
if (dayInMonth > 31)
{
ok = NO;
continue; /* error, value to large */
continue; /* error, value too large */
}
if (dayInMonth < -31)
{
ok = NO;
continue; /* error, value to large */
continue; /* error, value too large */
}

/* adjust negative days */
Expand Down Expand Up @@ -160,7 +160,7 @@ - (BOOL) _addInstanceWithStartDate: (NSCalendarDate *)_startDate
/* create range and check whether its in the requested range */

r = [[NGCalendarDateRange alloc] initWithStartDate: _startDate endDate: end];
if ([_r containsDateRange: r])
if ([_r doesIntersectWithDateRange: r])
[_ranges addObject: r];
[r release];
r = nil;
Expand Down

0 comments on commit aaaa16e

Please sign in to comment.