1.2 2805 lines 1.4 2813 lines *** /tmp/,azic.c 2014-05-01 01:51:36.998933800 -0400 --- /tmp/,bzic.c 2014-05-01 01:51:37.092534000 -0400 *************** *** 1480,1493 **** fromi = 0; while (fromi < timecnt && attypes[fromi].at < min_time) ++fromi; - if (isdsts[0] == 0) - while (fromi < timecnt && attypes[fromi].type == 0) - ++fromi; /* handled by default rule */ for ( ; fromi < timecnt; ++fromi) { ! if (toi != 0 && ((attypes[fromi].at + gmtoffs[attypes[toi - 1].type]) <= ! (attypes[toi - 1].at + gmtoffs[toi == 1 ? 0 ! : attypes[toi - 2].type]))) { attypes[toi - 1].type = attypes[fromi].type; continue; --- 1480,1490 ---- fromi = 0; while (fromi < timecnt && attypes[fromi].at < min_time) ++fromi; for ( ; fromi < timecnt; ++fromi) { ! if (toi > 1 && ((attypes[fromi].at + gmtoffs[attypes[toi - 1].type]) <= ! (attypes[toi - 1].at + ! gmtoffs[attypes[toi - 2].type]))) { attypes[toi - 1].type = attypes[fromi].type; continue; *************** *** 1532,1537 **** --- 1529,1541 ---- --timecnt32; ++timei32; } + /* + ** Output an INT32_MIN "transition" if appropriate--see below. + */ + if (timei32 > 0 && ats[timei32] > INT32_MIN) { + --timei32; + ++timecnt32; + } while (leapcnt32 > 0 && !is32(trans[leapcnt32 - 1])) --leapcnt32; while (leapcnt32 > 0 && !is32(trans[leapi32])) { *************** *** 1698,1704 **** #undef DO for (i = thistimei; i < thistimelim; ++i) if (pass == 1) ! puttzcode(ats[i], fp); else puttzcode64(ats[i], fp); for (i = thistimei; i < thistimelim; ++i) { unsigned char uc; --- 1702,1713 ---- #undef DO for (i = thistimei; i < thistimelim; ++i) if (pass == 1) ! /* ! ** Output an INT32_MIN "transition" ! ** if appropriate--see above. ! */ ! puttzcode(((ats[i] < INT32_MIN) ? ! INT32_MIN : ats[i]), fp); else puttzcode64(ats[i], fp); for (i = thistimei; i < thistimelim; ++i) { unsigned char uc; *************** *** 2176,2183 **** if (usestart) { addtt(starttime, type); usestart = FALSE; ! } else if (stdoff != 0) ! addtt(min_time, type); } else for (year = min_year; year <= max_year; ++year) { if (useuntil && year > zp->z_untilrule.r_hiyear) break; --- 2185,2191 ---- if (usestart) { addtt(starttime, type); usestart = FALSE; ! } else addtt(min_time, type); } else for (year = min_year; year <= max_year; ++year) { if (useuntil && year > zp->z_untilrule.r_hiyear) break;