From: Christoph M. Becker Date: Mon, 30 Nov 2020 11:32:45 +0000 (+0100) Subject: Merge branch 'PHP-7.4' into PHP-8.0 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=666833b238759e4f08bfa138f61c8038efb738b5;p=php Merge branch 'PHP-7.4' into PHP-8.0 * PHP-7.4: Fix #76813: Access violation near NULL on source operand --- 666833b238759e4f08bfa138f61c8038efb738b5 diff --cc NEWS index bd7d3b62ae,6943db07f6..ecb0ec0142 --- a/NEWS +++ b/NEWS @@@ -27,8 -24,13 +27,11 @@@ PH . Fixed bug #80368 (OpenSSL extension fails to build against LibreSSL due to lack of OCB support). (Nikita) + - Phpdbg: + . Fixed bug #76813 (Access violation near NULL on source operand). (cmb) + - Standard: . Fixed bug #80366 (Return Value of zend_fstat() not Checked). (sagpant, cmb) - . Fixed bug #80411 (References to null-serialized object break serialize()). - (Nikita) - Tidy: . Fixed bug #77594 (ob_tidyhandler is never reset). (cmb) diff --cc sapi/phpdbg/phpdbg_parser.y index f776586810,4c4a339c0a..cdfe92570e --- a/sapi/phpdbg/phpdbg_parser.y +++ b/sapi/phpdbg/phpdbg_parser.y @@@ -63,11 -63,15 +63,15 @@@ ZEND_EXTERN_MODULE_GLOBALS(phpdbg %% /* Rules */ input - : command { $$ = $1; } - | input T_SEPARATOR command { phpdbg_stack_separate($1.top); $$ = $3; } + : non_empty_input { $$ = $1; } - | /* empty */ + | %empty ; + non_empty_input + : command { $$ = $1; } + | non_empty_input T_SEPARATOR command { phpdbg_stack_separate($1.top); $$ = $3; } + ; + command : parameters { $$.top = PHPDBG_G(parser_stack)->top; } | full_expression { phpdbg_stack_push(PHPDBG_G(parser_stack), &$1); $$.top = PHPDBG_G(parser_stack)->top; }