X-Git-Url: https://git.m6w6.name/?a=blobdiff_plain;f=php_http_api.h;h=61ae827784c3101d1341983f7f093bf82b178773;hb=f8f0fd4dc265150a309824448b08249151d2ec45;hp=34a01597587f25aad7ec29de69c2de536ce28833;hpb=7dedd1935ab8400dfbd49fe63c83b74b0d0b68e6;p=m6w6%2Fext-http diff --git a/php_http_api.h b/php_http_api.h index 34a0159..61ae827 100644 --- a/php_http_api.h +++ b/php_http_api.h @@ -24,6 +24,10 @@ #define PHP_HTTP_API #endif +#ifndef ZEND_ENGINE_2 +#include "php_http_build_query.h" +#endif + /* make functions that return SUCCESS|FAILURE more obvious */ typedef int STATUS; @@ -52,7 +56,7 @@ typedef enum { #define HTTP_SERVER_VARS Z_ARRVAL_P(PG(http_globals)[TRACK_VARS_SERVER]) /* {{{ HAVE_CURL */ -#if defined(HAVE_CURL) && HAVE_CURL +#ifdef HTTP_HAVE_CURL /* CURL buffer size */ #define HTTP_CURLBUF_BODYSIZE 16384 @@ -149,7 +153,7 @@ PHP_HTTP_API STATUS _http_chunked_decode(const char *encoded, const size_t encod PHP_HTTP_API void _http_split_response(const zval *zresponse, zval *zheaders, zval *zbody TSRMLS_DC); /* {{{ HAVE_CURL */ -#if defined(HAVE_CURL) && HAVE_CURL +#ifdef HTTP_HAVE_CURL #define http_get(u, o, i, d, l) _http_get((u), (o), (i), (d), (l) TSRMLS_CC) PHP_HTTP_API STATUS _http_get(const char *URL, HashTable *options, HashTable *info, char **data, size_t *data_len TSRMLS_DC);