com php-src: emalloc never returns NULL (partially fix for #71753): ext/standard/http_fopen_wrapper.c
| From: | Xinchen Hui | Date: | Thu, 10 Mar 2016 07:15:26 +0000 |
| Subject: | com php-src: emalloc never returns NULL (partially fix for #71753): ext/standard/http_fopen_wrapper.c | ||
| Groups: | php.cvs | ||
| Request: | Send a blank email to php-cvs+get-91310@lists.php.net to get a copy of this message | ||
Commit: c3cf6f2a682eb25d0a52bef77386f155115efc13
Author: Xinchen Hui <laruence@gmail.com> Thu, 10 Mar 2016 15:15:26 +0800
Parents: 675c295722192cf394987cca2e36caddd4d0d038
Branches: PHP-7.0
Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=c3cf6f2a682eb25d0a52bef77386f155115efc13
Log:
emalloc never returns NULL (partially fix for #71753)
Bugs:
https://bugs.php.net/71753
Changed paths:
M ext/standard/http_fopen_wrapper.c
Diff:
diff --git a/ext/standard/http_fopen_wrapper.c b/ext/standard/http_fopen_wrapper.c
index 141ba0f..02b580f 100644
--- a/ext/standard/http_fopen_wrapper.c
+++ b/ext/standard/http_fopen_wrapper.c
@@ -614,10 +614,7 @@ finish:
} else {
php_error_docref(NULL, E_WARNING, "Cannot construct User-agent header");
}
-
- if (ua) {
- efree(ua);
- }
+ efree(ua);
}
}