File tree Expand file tree Collapse file tree 2 files changed +9
-3
lines changed Expand file tree Collapse file tree 2 files changed +9
-3
lines changed Original file line number Diff line number Diff line change 2
2
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
3
3
?? ??? ????, PHP 7.3.23
4
4
5
+ - Calendar:
6
+ . Fixed bug #80007 (Potential type confusion in unixtojd() parameter parsing).
7
+ (Andy Postnikov)
5
8
6
9
03 Sep 2020, PHP 7.3.22
7
10
Original file line number Diff line number Diff line change 28
28
PHP_FUNCTION (unixtojd )
29
29
{
30
30
time_t ts = 0 ;
31
+ zend_long tl = 0 ;
31
32
struct tm * ta , tmbuf ;
32
33
33
- if (zend_parse_parameters (ZEND_NUM_ARGS (), "|l" , & ts ) == FAILURE ) {
34
+ if (zend_parse_parameters (ZEND_NUM_ARGS (), "|l" , & tl ) == FAILURE ) {
34
35
return ;
35
36
}
36
37
37
- if (!ts ) {
38
+ if (!tl ) {
38
39
ts = time (NULL );
39
- } else if (ts < 0 ) {
40
+ } else if (tl >= 0 ) {
41
+ ts = (time_t ) tl ;
42
+ } else {
40
43
RETURN_FALSE ;
41
44
}
42
45
You can’t perform that action at this time.
0 commit comments