0
0
mirror of https://github.com/phpv8/v8js.git synced 2024-09-19 00:25:18 +00:00

Fix for V8 timezone notification

This commit is contained in:
Mark Grainger 2022-05-30 20:24:55 +00:00
parent 362868888f
commit 51d34e0acd
2 changed files with 5 additions and 7 deletions

View File

@ -1,8 +1,6 @@
--TEST--
Test V8::executeString() : Check timezone handling
--SKIPIF--
SKIP test currently broken, see #378
<?php
if(strtoupper(substr(PHP_OS, 0, 3)) === 'WIN') {
die('SKIP TZ not handled by v8 on Windows');
@ -39,7 +37,7 @@ try {
?>
===EOF===
--EXPECT--
Thu Mar 20 2014 11:03:24 GMT+0200 (EET)
Thu Mar 20 2014 05:03:24 GMT-0400 (EDT)
Thu Mar 20 2014 11:03:24 GMT+0200 (EET)
===EOF===
Thu Mar 20 2014 11:03:24 GMT+0200 (Eastern European Standard Time)
Thu Mar 20 2014 05:03:24 GMT-0400 (Eastern Daylight Time)
Thu Mar 20 2014 11:03:24 GMT+0200 (Eastern European Standard Time)
===EOF===

View File

@ -148,7 +148,7 @@ void v8js_v8_call(v8js_ctx *c, zval **return_value,
c->tz = strdup(tz);
}
else if (strcmp(c->tz, tz) != 0) {
c->isolate->DateTimeConfigurationChangeNotification();
c->isolate->DateTimeConfigurationChangeNotification(v8::Isolate::TimeZoneDetection::kRedetect);
free(c->tz);
c->tz = strdup(tz);