[horde] RRULE in .ics file contains wrong timestamp in field UNTIL
Pulz, Joerg
Joerg.Pulz at frm2.tum.de
Mon Oct 6 12:39:58 UTC 2014
Hi,
during debugging CalDAV sync problems for recurring events i found the
following bug.
The generated .ics file for recurring events contains several RRULE entries.
Many of those RRULE entries contain a field UNTIL with a timestamp.
This timestamp should be in the format:
YYYYMMDDTHHMMSSZ but in the .ics file it is
YYYYMMDDTHHMSSZ.
After digging in the code i found the following 3 times in
"framework/Timezone/lib/Horde/Timezone/Rule.php":
$until = ';UNTIL=' . $last->format('Ymd\THIs') . 'Z';
This is obviously wrong as "I" (capital i) means "Whether or not the
date is in daylight saving time" and is set to "1 if Daylight Saving
Time, 0 otherwise". (out of the php documentation)
I changed the 3 lines in the code to this:
$until = ';UNTIL=' . $last->format('Ymd\THis') . 'Z';
and everything is working now. CalDAV syncing is working and .ics
export shows the correct timestamp.
Only for clarification: "i" means "Minutes with leading zeros" and is
set to "00 to 59". (out of the php documentation)
A complete patch for "framework/Timezone/lib/Horde/Timezone/Rule.php"
is attached.
It would be nice if someone could take a look at it and commits the patch.
Kind regards
Joerg
-------------- next part --------------
A non-text attachment was scrubbed...
Name: framework_Timezone_lib_Horde_Timezone_Rule.php
Type: application/x-httpd-php
Size: 1571 bytes
Desc: not available
URL: <http://lists.horde.org/archives/horde/attachments/20141006/fd19d6e3/attachment.bin>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/pkcs7-signature
Size: 5262 bytes
Desc: S/MIME Signature
URL: <http://lists.horde.org/archives/horde/attachments/20141006/fd19d6e3/attachment-0001.bin>
More information about the horde
mailing list