stas Wed Jun 4 14:06:19 2008 UTC
Modified files: (Branch: PHP_4_4)
/php-src/ext/curl curl.c
Log:
fix open_basedir handling bug
http://cvs.php.net/viewvc.cgi/php-src/ext/curl/curl.c?r1=1.124.2.30.2.20&r2=1.124.2.30.2.21&diff_format=u
Index: php-src/ext/curl/curl.c
diff -u php-src/ext/curl/curl.c:1.124.2.30.2.20
php-src/ext/curl/curl.c:1.124.2.30.2.21
--- php-src/ext/curl/curl.c:1.124.2.30.2.20 Mon Dec 31 07:22:45 2007
+++ php-src/ext/curl/curl.c Wed Jun 4 14:06:19 2008
@@ -16,7 +16,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: curl.c,v 1.124.2.30.2.20 2007/12/31 07:22:45 sebastian Exp $ */
+/* $Id: curl.c,v 1.124.2.30.2.21 2008/06/04 14:06:19 stas Exp $ */
#ifdef HAVE_CONFIG_H
#include "config.h"
@@ -169,8 +169,9 @@
RETURN_FALSE;
\
}
\
\
- if (php_memnstr(str, tmp_url->path, strlen(tmp_url->path), str
+ len)) { \
+ if (tmp_url->host || !php_memnstr(str, tmp_url->path,
strlen(tmp_url->path), str + len)) { \
php_error_docref(NULL TSRMLS_CC, E_WARNING, "Url '%s'
contains unencoded control characters.", str); \
+ php_url_free(tmp_url);
\
RETURN_FALSE;
\
}
\
\-- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
