mirror of
https://frontier.innolan.net/rainlance/amiga-tz.git
synced 2025-12-09 16:43:00 +00:00
documentation
SCCS-file: zic.c SCCS-SID: 1.4
This commit is contained in:
committed by
Paul Eggert
parent
8d5ac714bf
commit
718b7a67a3
10
zic.c
10
zic.c
@ -741,7 +741,7 @@ struct temp {
|
|||||||
struct rule * t_rp;
|
struct rule * t_rp;
|
||||||
};
|
};
|
||||||
|
|
||||||
static struct temp temps[TZ_MAX_RULES];
|
static struct temp temps[TZ_MAX_TIMES];
|
||||||
static int ntemps;
|
static int ntemps;
|
||||||
|
|
||||||
static
|
static
|
||||||
@ -773,7 +773,7 @@ static
|
|||||||
addrule(rp, y)
|
addrule(rp, y)
|
||||||
register struct rule * rp;
|
register struct rule * rp;
|
||||||
{
|
{
|
||||||
if (ntemps >= TZ_MAX_RULES) {
|
if (ntemps >= TZ_MAX_TIMES) {
|
||||||
filename = rp->r_filename;
|
filename = rp->r_filename;
|
||||||
linenum = rp->r_linenum;
|
linenum = rp->r_linenum;
|
||||||
error("too many transitions?!");
|
error("too many transitions?!");
|
||||||
@ -803,14 +803,14 @@ register struct zone * zp;
|
|||||||
linenum = zp->z_linenum;
|
linenum = zp->z_linenum;
|
||||||
t = tzero;
|
t = tzero;
|
||||||
if (zp->z_nrules == 0) { /* Piece of cake! */
|
if (zp->z_nrules == 0) { /* Piece of cake! */
|
||||||
t.tz_rulecnt = 0;
|
t.tz_timecnt = 0;
|
||||||
t.tz_dsinfo[0].ds_gmtoff = zp->z_gmtoff;
|
t.tz_dsinfo[0].ds_gmtoff = zp->z_gmtoff;
|
||||||
t.tz_dsinfo[0].ds_isdst = 0;
|
t.tz_dsinfo[0].ds_isdst = 0;
|
||||||
(void) strcpy(t.tz_dsinfo[0].ds_abbr, zp->z_format);
|
(void) strcpy(t.tz_dsinfo[0].ds_abbr, zp->z_format);
|
||||||
writezone(zp->z_name, &t);
|
writezone(zp->z_name, &t);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
t.tz_rulecnt = 0;
|
t.tz_timecnt = 0;
|
||||||
/*
|
/*
|
||||||
** See what the different Saving Time types are.
|
** See what the different Saving Time types are.
|
||||||
** Plug the indices into the rules.
|
** Plug the indices into the rules.
|
||||||
@ -854,7 +854,7 @@ register struct zone * zp;
|
|||||||
else for (y = rp->r_loyear; y <= rp->r_hiyear; ++y)
|
else for (y = rp->r_loyear; y <= rp->r_hiyear; ++y)
|
||||||
addrule(rp, y);
|
addrule(rp, y);
|
||||||
}
|
}
|
||||||
t.tz_rulecnt = ntemps;
|
t.tz_timecnt = ntemps;
|
||||||
(void) qsort((char *) temps, ntemps, sizeof *temps, tcomp);
|
(void) qsort((char *) temps, ntemps, sizeof *temps, tcomp);
|
||||||
for (i = 0; i < ntemps; ++i) {
|
for (i = 0; i < ntemps; ++i) {
|
||||||
t.tz_times[i] = temps[i].t_time - zp->z_gmtoff;
|
t.tz_times[i] = temps[i].t_time - zp->z_gmtoff;
|
||||||
|
|||||||
Reference in New Issue
Block a user