xref: /PHP-8.3/ext/calendar/tests/bug71894.phpt (revision 56f90492)
1--TEST--
2Bug #71894 (AddressSanitizer: global-buffer-overflow in zif_cal_from_jd)
3--EXTENSIONS--
4calendar
5--FILE--
6<?php
7var_dump(cal_from_jd(347997, CAL_JEWISH));
8var_dump(jdmonthname(347997,CAL_MONTH_JEWISH));?>
9--EXPECT--
10array(9) {
11  ["date"]=>
12  string(5) "0/0/0"
13  ["month"]=>
14  int(0)
15  ["day"]=>
16  int(0)
17  ["year"]=>
18  int(0)
19  ["dow"]=>
20  NULL
21  ["abbrevdayname"]=>
22  string(0) ""
23  ["dayname"]=>
24  string(0) ""
25  ["abbrevmonth"]=>
26  string(0) ""
27  ["monthname"]=>
28  string(0) ""
29}
30string(0) ""
31