Comment 1 for bug 1424924

Revision history for this message
Charles Kerr (charlesk) wrote : Re: clock-app alarms' RRULE have unusual X-EVOLUTION-ENDDATE, causing alarms to not sound

"X-EVOLUTION-ENDDATE" is set only in one place, evolution-data-server/calendar/libecal/e-cal-recur.c's function , e_cal_recur_set_rule_end_date(), which is only called in this block:

> /* Calculate the end date. Note that we initialize end_date to 0, so
> * if the RULE doesn't generate COUNT instances we save a time_t of 0.
> * Also note that we use the UTC timezone as the default timezone.
> * In get_end_date () if the DTSTART is a DATE or floating time, we will
> * convert the ENDDATE to the current timezone. */
> cb_data.count = rule.count;
> cb_data.instances = 0;
> cb_data.end_date = 0;
> e_cal_recur_generate_instances_of_rule (
> comp, prop, -1, -1,
> e_cal_recur_ensure_rule_end_date_cb,
> &cb_data, tz_cb, tz_cb_data,
> icaltimezone_get_utc_timezone ());
>
> /* Store the end date in the "X-EVOLUTION-ENDDATE" parameter of the
> * rule. */
> e_cal_recur_set_rule_end_date (prop, cb_data.end_date);

It looks like somehow e_cal_recur_generate_instances_of_rule() here generated no instances so that end_date became the epoch.