Annotation of embedaddon/php/ext/calendar/tests/bug55797_2.phpt, revision 1.1.1.1
1.1 misho 1: --TEST--
2: Bug #55797: Integer overflow in SdnToGregorian leads to segfault (in optimized builds)
3: --SKIPIF--
4: <?php
5: include 'skipif.inc';
6: if (PHP_INT_SIZE == 4) {
7: die("skip this test is for 64bit platform only");
8: }
9: ?>
10: --FILE--
11: <?php
12: $x = 9223372036854743639;
13:
14: var_dump(cal_from_jd($x, CAL_GREGORIAN));
15: --EXPECTF--
16: array(9) {
17: ["date"]=>
18: string(5) "0/0/0"
19: ["month"]=>
20: int(0)
21: ["day"]=>
22: int(0)
23: ["year"]=>
24: int(0)
25: ["dow"]=>
26: int(%d)
27: ["abbrevdayname"]=>
28: string(%d) "%s"
29: ["dayname"]=>
30: string(%d) "%s"
31: ["abbrevmonth"]=>
32: string(0) ""
33: ["monthname"]=>
34: string(0) ""
35: }
36:
FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>