Skip to content

Commit 25103c3

Browse files
committed
Revert "Fix #76813: Access violation near NULL on source operand"
This reverts commit 5e15c9c, since re2c default rules are only available as of re2c 0.13.7.
1 parent 9450893 commit 25103c3

File tree

4 files changed

+3
-24
lines changed

4 files changed

+3
-24
lines changed

NEWS

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -72,9 +72,6 @@ PHP NEWS
7272
. Fixed bug #76815 (PDOStatement cannot be GCed/closeCursor-ed when a
7373
PROCEDURE resultset SIGNAL). (Nikita)
7474

75-
- Phpdbg:
76-
. Fixed bug #76813 (Access violation near NULL on source operand). (cmb)
77-
7875
- Standard:
7976
. Fixed bug #77423 (FILTER_VALIDATE_URL accepts URLs with invalid userinfo).
8077
(CVE-2020-7071) (cmb)

sapi/phpdbg/phpdbg_lexer.l

Lines changed: 1 addition & 5 deletions
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

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -63,13 +63,9 @@ typedef void* yyscan_t;
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

Lines changed: 0 additions & 10 deletions
This file was deleted.

0 commit comments

Comments
 (0)