Skip to content

Commit a9a084c

Browse files
committed
Update API use due to changes in timelib 2018.01RC3
1 parent 3e4a3d0 commit a9a084c

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

ext/date/php_date.c

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4032,7 +4032,7 @@ PHP_FUNCTION(timezone_transitions_get)
40324032
add_assoc_string(&element, "abbr", &tzobj->tzi.tz->timezone_abbr[tzobj->tzi.tz->type[tzobj->tzi.tz->trans_idx[i]].abbr_idx]); \
40334033
add_next_index_zval(return_value, &element);
40344034

4035-
#define add_last() add(tzobj->tzi.tz->bit32.timecnt - 1, timestamp_begin)
4035+
#define add_last() add(tzobj->tzi.tz->bit64.timecnt - 1, timestamp_begin)
40364036

40374037
array_init(return_value);
40384038

@@ -4043,7 +4043,7 @@ PHP_FUNCTION(timezone_transitions_get)
40434043
} else {
40444044
begin = 0;
40454045
found = 0;
4046-
if (tzobj->tzi.tz->bit32.timecnt > 0) {
4046+
if (tzobj->tzi.tz->bit64.timecnt > 0) {
40474047
do {
40484048
if (tzobj->tzi.tz->trans[begin] > timestamp_begin) {
40494049
if (begin > 0) {
@@ -4055,19 +4055,19 @@ PHP_FUNCTION(timezone_transitions_get)
40554055
break;
40564056
}
40574057
begin++;
4058-
} while (begin < tzobj->tzi.tz->bit32.timecnt);
4058+
} while (begin < tzobj->tzi.tz->bit64.timecnt);
40594059
}
40604060
}
40614061

40624062
if (!found) {
4063-
if (tzobj->tzi.tz->bit32.timecnt > 0) {
4063+
if (tzobj->tzi.tz->bit64.timecnt > 0) {
40644064
add_last();
40654065
} else {
40664066
add_nominal();
40674067
}
40684068
} else {
40694069
unsigned int i;
4070-
for (i = begin; i < tzobj->tzi.tz->bit32.timecnt; ++i) {
4070+
for (i = begin; i < tzobj->tzi.tz->bit64.timecnt; ++i) {
40714071
if (tzobj->tzi.tz->trans[i] < timestamp_end) {
40724072
add(i, tzobj->tzi.tz->trans[i]);
40734073
}

0 commit comments

Comments
 (0)