[dev] iCalendar parsing problem
Chuck Hagenbuch
chuck at horde.org
Thu Apr 1 19:25:24 PST 2004
Quoting Justus Pendleton <justus at ryoohki.net>:
> I tried using one of the shared calendars on www.icalshare.com with
> Kronolith with little success; the calendar is
> http://ical.mac.com/lilscoy/smallville.ics. After a little digging, the
> problem seems to be with a change made in version 1.37 of iCalendar.php
> in the framework. The regexp for finding subcomponents was changed from
> ungreedy to greedy, which looks wrong to me. When I took a look at the
> intermediate $data values during the parsevCalendar loop each successive
> iteration included not only the next subcomponent but also all previous
> subcomponents. When I changed the regexp to be ungreedy again, this was
> fixed. If that regexp is greedy it seems to me that it won't find the
> appropriate matching END:VEVENT tag.
With the code the way it is in CVS, I can use both the calendar I'd
been testing
on from icalshare.com (http://homepage.mac.com/ical/.calendars/Flyers.ics) and
your Smallville one and have events show up properly. If I revert the
greediness change, remove the /U at the end of the regexp, or both, then no
events show up. Your experience, actually, sounds exactly like what I was
seeing *before* I made that commit.
-chuck
--
"Regard my poor demoralized mule!" - Juan Valdez
More information about the dev
mailing list