We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
2 parents 3b022e5 + 8228597 commit ae5d862Copy full SHA for ae5d862
Zend/zend_highlight.c
@@ -186,7 +186,6 @@ ZEND_API void zend_strip(TSRMLS_D)
186
187
case T_END_HEREDOC:
188
zend_write((char*)LANG_SCNG(yy_text), LANG_SCNG(yy_leng));
189
- efree(token.value.str.val);
190
/* read the following character, either newline or ; */
191
if (lex_scan(&token TSRMLS_CC) != T_WHITESPACE) {
192
ext/standard/tests/strings/bug63874.phpt
@@ -0,0 +1,16 @@
1
+--TEST--
2
+Bug #63874 (Segfault if php_strip_whitespace has heredoc)
3
+--FILE--
4
+<?php
5
+echo php_strip_whitespace(__FILE__);
6
+
7
+return <<<A
8
+a
9
+A;
10
+?>
11
+--EXPECT--
12
13
+echo php_strip_whitespace(__FILE__); return <<<A
14
15
16
0 commit comments