Debian Patches

Status for libical3/3.0.20-3

Patch Description Author Forwarded Bugs Origin Last update
32-bit_time_t_upper_bound.patch icaltime: fix 32-bit time_t upper bound off by two days
make_time()'s SIZEOF_TIME_T==4 boundary check rejected any date
after 2038-01-17, two days before the actual limit of a signed 32-bit
time_t (2038-01-19T03:14:07 UTC, i.e. INT32_MAX seconds since the
epoch). Rejected dates silently fell through icaltime_timegm() as 0
(1970-01-01) instead of the correct value or an explicit error.

This corrupts any caller that uses time_t-max as an "unbounded end"
sentinel, a common calendar idiom: the sentinel round-trips to epoch,
so recurrence/timespan queries silently return truncated results
instead of "no upper bound". Confirmed via a real-world case: Debian
bug #1142273 (cyrus-imapd FTBFS on i386), traced to exactly this in
icalcomponent_foreach_recurrence().

The check has been wrong since it was introduced in 72330c96
(2001-2002); a related commit (ef907061) even called it "arguably a
bug" at the time and left it in place.

Replace the padded day-level approximation with an exact check
against the true boundary (year/month/day/hour/min/sec), and update
the two existing regression tests that had encoded the old, incorrect
cutoff as expected behavior.

Backport of the equivalent fix on the 4.0 branch
(libical/libical#1350) to this 3.0 branch, which is what several
distributions (e.g. Debian) still package.

originally-failing cyrus-imapd cunit test now passes unmodified
against a patched i386 libical.so.
Edmund Lodewijks <edmund@proteamail.com> no https://github.com/libical/libical/pull/1351 2026-07-26

All known versions for source package 'libical3'

Links