com php-src: improve fix for Bug #69545: NEWS ext/ftp/ftp.c
| From: | Stanislav Malyshev | Date: | Mon, 01 Jun 2015 00:29:00 +0000 |
| Subject: | com php-src: improve fix for Bug #69545: NEWS ext/ftp/ftp.c | ||
| Groups: | php.cvs | ||
| Request: | Send a blank email to php-cvs+get-87027@lists.php.net to get a copy of this message | ||
Commit: 0765623d6991b62ffcd93ddb6be8a5203a2fa7e2
Author: Stanislav Malyshev <stas@php.net> Sun, 31 May 2015 17:23:06 -0700
Parents: f38ca75a3cc5737bdb922dc5e2a7505cd20cd7ea
Branches: PHP-5.4 PHP-5.5 PHP-5.6 master
Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=0765623d6991b62ffcd93ddb6be8a5203a2fa7e2
Log:
improve fix for Bug #69545
Bugs:
https://bugs.php.net/69545
Changed paths:
M NEWS
M ext/ftp/ftp.c
Diff:
diff --git a/NEWS b/NEWS
index effd8ff..3713ea9 100644
--- a/NEWS
+++ b/NEWS
@@ -2,6 +2,10 @@ PHP NEWS
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
?? ??? 2015 PHP 5.4.42
+- Core:
+ . Imroved fix for bug #69545 (Integer overflow in ftp_genlist() resulting in
+ heap overflow). (Max Spelsberg)
+
- Postgres:
. Fixed bug #69667 (segfault in php_pgsql_meta_data). (Remi)
diff --git a/ext/ftp/ftp.c b/ext/ftp/ftp.c
index 53560eb..50d8def 100644
--- a/ext/ftp/ftp.c
+++ b/ext/ftp/ftp.c
@@ -1668,8 +1668,6 @@ ftp_genlist(ftpbuf_t *ftp, const char *cmd, const char *path TSRMLS_DC)
for (ptr = data->buf; rcvd; rcvd--, ptr++) {
if (*ptr == '\n' && lastch == '\r') {
lines++;
- } else {
- size++;
}
lastch = *ptr;
}