Update zic from tzcode 2013b.

This commit is contained in:
Joseph Myers 2013-03-13 01:54:00 +00:00
parent e98cdb38ee
commit 54206aa6a2
2 changed files with 8 additions and 2 deletions

View File

@ -1,3 +1,7 @@
2013-03-13 Joseph Myers <joseph@codesourcery.com>
* timezone/zic.c: Update from tzcode 2013b.
2013-03-12 Carlos O'Donell <carlos@redhat.com> 2013-03-12 Carlos O'Donell <carlos@redhat.com>
* manual/install.texi (Configuring and compiling): * manual/install.texi (Configuring and compiling):

View File

@ -1748,7 +1748,7 @@ stringoffset(char *result, long offset)
minutes = offset % MINSPERHOUR; minutes = offset % MINSPERHOUR;
offset /= MINSPERHOUR; offset /= MINSPERHOUR;
hours = offset; hours = offset;
if (hours >= HOURSPERDAY) { if (hours > HOURSPERDAY) {
result[0] = '\0'; result[0] = '\0';
return -1; return -1;
} }
@ -1851,7 +1851,9 @@ stringzone(char *result, const struct zone *const zpfirst, const int zonecount)
rp = &zp->z_rules[i]; rp = &zp->z_rules[i];
if (stdrp == NULL || rp->r_hiyear > stdrp->r_hiyear || if (stdrp == NULL || rp->r_hiyear > stdrp->r_hiyear ||
(rp->r_hiyear == stdrp->r_hiyear && (rp->r_hiyear == stdrp->r_hiyear &&
rp->r_month > stdrp->r_month)) (rp->r_month > stdrp->r_month ||
(rp->r_month == stdrp->r_month &&
rp->r_dayofmonth > stdrp->r_dayofmonth))))
stdrp = rp; stdrp = rp;
} }
if (stdrp != NULL && stdrp->r_stdoff != 0) if (stdrp != NULL && stdrp->r_stdoff != 0)