Skip to content

Commit 95a13ca

Browse files
committed
Revert fix for bug 76813 and re2c version bump
CentOS 7 ships with re2c 0.13.5 by default, so we should not have bumped the required re2c version to 0.13.7. However, 0.13.5 does not support default rules, so we cannot use them to fix bug 76813. This reverts commit 420184a and 5e15c9c. Closes GH-6593.
1 parent 52ed457 commit 95a13ca

File tree

5 files changed

+7
-22
lines changed

5 files changed

+7
-22
lines changed

NEWS

+3
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,9 @@ PHP NEWS
4444
(david at bamsoftware, cmb)
4545
. Fixed bug #77565 (Incorrect locator detection in ZIP-based phars). (cmb)
4646

47+
- Phpdbg:
48+
. Reverted fix for bug #76813 (Access violation near NULL on source operand).
49+
(cmb)
4750

4851
07 Jan 2021, PHP 8.0.1
4952

configure.ac

+1-1
Original file line numberDiff line numberDiff line change
@@ -154,7 +154,7 @@ PHP_RUNPATH_SWITCH
154154
dnl Checks for some support/generator progs.
155155
PHP_PROG_AWK
156156
PHP_PROG_BISON([3.0.0])
157-
PHP_PROG_RE2C([0.13.7])
157+
PHP_PROG_RE2C([0.13.4])
158158

159159
PHP_ARG_ENABLE([re2c-cgoto],
160160
[whether to enable computed goto gcc extension with re2c],

sapi/phpdbg/phpdbg_lexer.l

+1-5
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ void phpdbg_init_lexer (phpdbg_param_t *stack, char *input) {
3333

3434
YYSETCONDITION(INITIAL);
3535

36-
LEX(text) = YYCURSOR = YYMARKER = (unsigned char *) input;
36+
LEX(text) = YYCURSOR = (unsigned char *) input;
3737
LEX(len) = strlen(input);
3838
}
3939

@@ -165,10 +165,6 @@ INPUT ("\\"[#"']|["]("\\\\"|"\\"["]|[^\n\000"])+["]|[']("\\"[']|"\\\\"|[^\
165165
return T_ID;
166166
}
167167
168-
<NORMAL>* {
169-
return T_UNEXPECTED;
170-
}
171-
172168
<RAW>{INPUT} {
173169
phpdbg_init_param(yylval, STR_PARAM);
174170
yylval->str = estrdup(yytext);

sapi/phpdbg/phpdbg_parser.y

+2-6
Original file line numberDiff line numberDiff line change
@@ -63,13 +63,9 @@ ZEND_EXTERN_MODULE_GLOBALS(phpdbg)
6363
%% /* Rules */
6464

6565
input
66-
: non_empty_input { $$ = $1; }
67-
| %empty
68-
;
69-
70-
non_empty_input
7166
: command { $$ = $1; }
72-
| non_empty_input T_SEPARATOR command { phpdbg_stack_separate($1.top); $$ = $3; }
67+
| input T_SEPARATOR command { phpdbg_stack_separate($1.top); $$ = $3; }
68+
| %empty
7369
;
7470

7571
command

sapi/phpdbg/tests/bug76813.phpt

-10
This file was deleted.

0 commit comments

Comments
 (0)