mirror of
https://frontier.innolan.net/rainlance/amiga-tz.git
synced 2025-11-22 00:12:32 +00:00
* zdump.c (main): Fix bug with 'zdump -Vc 1981,1982 Asia/Singapore'
missing the end-of-1981 transition. Problem reported by Tim Parenti in: http://mm.icann.org/pipermail/tz/2014-September/021565.html
This commit is contained in:
3
NEWS
3
NEWS
@ -17,6 +17,9 @@ Unreleased, experimental changes
|
||||
|
||||
Changes affecting code
|
||||
|
||||
zdump -c no longer mishandles transitions near year boundaries.
|
||||
(Thanks to Tim Parenti for reporting the problem.)
|
||||
|
||||
An access to uninitalized data has been fixed.
|
||||
(Thanks to Jörg Richter for reporting the problem.)
|
||||
|
||||
|
||||
9
zdump.c
9
zdump.c
@ -654,12 +654,11 @@ main(int argc, char *argv[])
|
||||
tmp = my_localtime_rz(tz, &t, &tm);
|
||||
if (tmp)
|
||||
ab = saveabbr(&abbrev, &abbrevsize, &tm);
|
||||
for ( ; ; ) {
|
||||
newt = (t < absolute_max_time - SECSPERDAY / 2
|
||||
while (t < cuthitime) {
|
||||
newt = ((t < absolute_max_time - SECSPERDAY / 2
|
||||
&& t + SECSPERDAY / 2 < cuthitime)
|
||||
? t + SECSPERDAY / 2
|
||||
: absolute_max_time);
|
||||
if (cuthitime <= newt)
|
||||
break;
|
||||
: cuthitime);
|
||||
newtmp = localtime_rz(tz, &newt, &newtm);
|
||||
if ((tmp == NULL || newtmp == NULL) ? (tmp != newtmp) :
|
||||
(delta(&newtm, &tm) != (newt - t) ||
|
||||
|
||||
Reference in New Issue
Block a user