}
/* }}} */
-#if PHP_MAJOR_VERSION == 4 && PHP_MINOR_VERSION == 3 && PHP_RELEASE_VERSION < 10
-# define php_url_parse_ex(u, l) php_url_parse(u)
-#endif
-
/* {{{ proto string http_build_url([mixed url[, mixed parts[, int flags = HTTP_URL_REPLACE[, array &new_url]]]])
Build an URL. */
PHP_FUNCTION(http_build_url)
# include "php_http_persistent_handle_api.h"
#endif
-#ifndef HAVE_CURL_SHARE_STRERROR
-# define curl_share_strerror(dummy) "unknown error"
-#endif
-#ifndef HAVE_CURL_EASY_STRERROR
-# define curl_easy_strerror(dummy) "unknown error"
-#endif
-
#ifdef HTTP_HAVE_PERSISTENT_HANDLES
# define HTTP_CURL_SHARE_CTOR(ch) (SUCCESS == http_persistent_handle_acquire("http_request_datashare", &(ch)))
# define HTTP_CURL_SHARE_DTOR(chp) http_persistent_handle_release("http_request_datashare", (chp))
# define HTTP_DEBUG_REQPOOLS 0
#endif
-#ifndef HAVE_CURL_MULTI_STRERROR
-# define curl_multi_strerror(dummy) "unknown error"
-#endif
-
#ifdef HTTP_HAVE_PERSISTENT_HANDLES
# define HTTP_CURL_MULTI_CTOR(ch) (SUCCESS == http_persistent_handle_acquire("http_request_pool", &(ch)))
# define HTTP_CURL_MULTI_DTOR(chp) http_persistent_handle_release("http_request_pool", (chp))
# endif /* PHP_WIN32 */
#endif /* ZTS && HTTP_HAVE_SSL */
-#ifndef HAVE_CURL_EASY_STRERROR
-# define curl_easy_strerror(dummy) "unknown error"
-#endif
-
#define HTTP_CURL_OPT(OPTION, p) curl_easy_setopt((request->ch), OPTION, (p))
#define HTTP_CURL_OPT_STRING(OPTION, ldiff, obdc) \
# define ACC_PROP_PUBLIC(flags) (flags & ZEND_ACC_PUBLIC)
# define ACC_PROP(ce, flags) (ACC_PROP_PUBLIC(flags) || ACC_PROP_PRIVATE(ce, flags) || ACC_PROP_PROTECTED(ce, flags))
-# define SET_EH_THROW() SET_EH_THROW_EX(zend_exception_get_default())
# define SET_EH_THROW_HTTP() SET_EH_THROW_EX(http_exception_get_default())
# define SET_EH_THROW_EX(ex) php_set_error_handling(EH_THROW, ex TSRMLS_CC)
# define SET_EH_NORMAL() php_set_error_handling(EH_NORMAL, NULL TSRMLS_CC)
# define ZEND_EXCEPTION_GET_DEFAULT() zend_exception_get_default()
#endif
+#if PHP_MAJOR_VERSION == 4 && PHP_MINOR_VERSION == 3 && PHP_RELEASE_VERSION < 10
+# define php_url_parse_ex(u, l) php_url_parse(u)
+#endif
+
#ifndef E_THROW
# define E_THROW 0
#endif
#endif /* HTTP_HAVE_CURL */
+#ifndef HAVE_CURL_SHARE_STRERROR
+# define curl_share_strerror(dummy) "unknown error"
+#endif
+#ifndef HAVE_CURL_EASY_STRERROR
+# define curl_easy_strerror(dummy) "unknown error"
+#endif
+#ifndef HAVE_CURL_MULTI_STRERROR
+# define curl_multi_strerror(dummy) "unknown error"
+#endif
+
#ifndef TSRMLS_FETCH_FROM_CTX
# ifdef ZTS
# define TSRMLS_FETCH_FROM_CTX(ctx) void ***tsrm_ls = (void ***) ctx