xref: /PHP-8.0/ext/com_dotnet/tests/bug72498.phpt (revision e55f0c79)
1--TEST--
2Bug #72498 variant_date_from_timestamp null dereference
3--SKIPIF--
4<?php
5if (!extension_loaded("com_dotnet")) print "skip COM/.Net support not present";
6?>
7--FILE--
8<?php
9
10$v1 = PHP_INT_MAX;
11
12try {
13    var_dump(variant_date_from_timestamp($v1));
14} catch (\ValueError $e) {
15    echo $e->getMessage() . \PHP_EOL;
16}
17?>
18--EXPECT--
19variant_date_from_timestamp(): Argument #1 ($timestamp) must not go past 23:59:59, December 31, 3000, UTC
20