com php-src: fixed bug, where a linebreak immediately after an opening quote of a value caused a segfault: Zend/zend_ini_scanner .l
| From: | Anatol Belski | Date: | Wed, 10 Jun 2015 08:39:37 +0000 |
| Subject: | com php-src: fixed bug, where a linebreak immediately after an opening quote of a value caused a segfault: Zend/zend_ini_scanner .l | ||
| Groups: | php.cvs | ||
| Request: | Send a blank email to php-cvs+get-87158@lists.php.net to get a copy of this message | ||
Commit: 36222eb4cc9eb13a861e0291671aa15ffa98d4d5
Author: Christoph M. Becker <cmbecker69@gmx.de> Thu, 4 Jun 2015 02:40:05 +0200
Committer: Anatol Belski <ab@php.net> Wed, 10 Jun 2015 10:39:37 +0200
Parents: 2ba9681e8efaeddb96a0e2e7d43c50df363d8723
Branches: PHP-5.5 PHP-5.6 master
Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=36222eb4cc9eb13a861e0291671aa15ffa98d4d5
Log:
fixed bug, where a linebreak immediately after an opening quote of a value caused a segfault
Changed paths:
M Zend/zend_ini_scanner.l
Diff:
diff --git a/Zend/zend_ini_scanner.l b/Zend/zend_ini_scanner.l
index a0a4df7...6019bf2 100644
--- a/Zend/zend_ini_scanner.l
+++ b/Zend/zend_ini_scanner.l
@@ -472,7 +472,7 @@ end_raw_value_chars:
}
/* Eat leading and trailing double quotes */
- if (yytext[0] == '"' && yytext[yyleng - 1] == '"') {
+ if (yyleng > 1 && yytext[0] == '"' && yytext[yyleng - 1] ==
'"') {
SCNG(yy_text)++;
yyleng = yyleng - 2;
} else if (sc) {