Skip to content

Commit f6bd3df

Browse files
committed
Merge branch 'PHP-7.4' into PHP-8.0
* PHP-7.4: Fix bug #80523
2 parents e586a35 + 118ff03 commit f6bd3df

File tree

2 files changed

+5
-3
lines changed

2 files changed

+5
-3
lines changed

NEWS

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,8 @@ PHP NEWS
22
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
33
?? ??? ????, PHP 8.0.2RC1
44

5+
- Core:
6+
. Fixed bug #80523 (bogus parse error on >4GB source code). (Nikita)
57

68
07 Jan 2021, PHP 8.0.1
79

Zend/zend_language_scanner.l

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -177,7 +177,7 @@ static void yy_pop_state(void)
177177
zend_stack_del_top(&SCNG(state_stack));
178178
}
179179

180-
static void yy_scan_buffer(char *str, unsigned int len)
180+
static void yy_scan_buffer(char *str, size_t len)
181181
{
182182
YYCURSOR = (YYCTYPE*)str;
183183
YYLIMIT = YYCURSOR + len;
@@ -571,7 +571,7 @@ ZEND_API zend_result open_file_for_scanning(zend_file_handle *file_handle)
571571
}
572572
}
573573
SCNG(yy_start) = (unsigned char *)buf;
574-
yy_scan_buffer(buf, (unsigned int)size);
574+
yy_scan_buffer(buf, size);
575575
} else {
576576
zend_error_noreturn(E_COMPILE_ERROR, "zend_stream_mmap() failed");
577577
}
@@ -772,7 +772,7 @@ ZEND_API void zend_prepare_string_for_scanning(zval *str, const char *filename)
772772
}
773773
}
774774

775-
yy_scan_buffer(buf, (unsigned int)size);
775+
yy_scan_buffer(buf, size);
776776

777777
new_compiled_filename = zend_string_init(filename, strlen(filename), 0);
778778
zend_set_compiled_filename(new_compiled_filename);

0 commit comments

Comments
 (0)