php-src/ext/date/tests/bug36988.phpt

17 lines
402 B
Plaintext
Raw Normal View History

--TEST--
Bug #36988 (mktime freezes on long numbers)
--SKIPIF--
<?php if (PHP_INT_SIZE != 4) echo "skip this test is for 32-bit only"; ?>
--FILE--
<?php
date_default_timezone_set('GMT');
$start = microtime(true);
2019-02-19 16:11:00 +00:00
try {
$a = mktime(1, 1, 1, 1, 1, 11111111111);
} catch (TypeError $e) {
echo $e->getMessage(), "\n";
}
?>
2019-02-19 16:11:00 +00:00
--EXPECT--
mktime(): Argument #6 ($year) must be of type ?int, float given