projects
/
m6w6
/
ext-http
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
|
github
raw
|
inline
| side by side
- avoid NULL urls
[m6w6/ext-http]
/
http_request_api.c
diff --git
a/http_request_api.c
b/http_request_api.c
index 6090bc15cf62e244a9b6deb55a1049fcbc7bbc90..d96c1808a9fb4d68b4c02ea4c8230f7786095e97 100644
(file)
--- a/
http_request_api.c
+++ b/
http_request_api.c
@@
-29,8
+29,6
@@
# include "php_http_request_object.h"
#endif
# include "php_http_request_object.h"
#endif
-ZEND_EXTERN_MODULE_GLOBALS(http);
-
/* {{{ cruft for thread safe SSL crypto locks */
#if defined(ZTS) && defined(HTTP_HAVE_SSL)
# ifdef PHP_WIN32
/* {{{ cruft for thread safe SSL crypto locks */
#if defined(ZTS) && defined(HTTP_HAVE_SSL)
# ifdef PHP_WIN32
@@
-224,7
+222,7
@@
PHP_HTTP_API http_request *_http_request_init_ex(http_request *request, CURL *ch
memset(r, 0, sizeof(http_request));
r->ch = ch;
memset(r, 0, sizeof(http_request));
r->ch = ch;
- r->url = (url
&& *url) ? estrdup
(url) : NULL;
+ r->url = (url
) ? http_absolute_url
(url) : NULL;
r->meth = (meth > 0) ? meth : HTTP_GET;
phpstr_init(&r->conv.request);
r->meth = (meth > 0) ? meth : HTTP_GET;
phpstr_init(&r->conv.request);