From: Michael Wallner Date: Mon, 21 Mar 2005 19:54:14 +0000 (+0000) Subject: * try the direct way X-Git-Tag: RELEASE_0_7_0~18 X-Git-Url: https://git.m6w6.name/?a=commitdiff_plain;h=79bfab50fb44032e89ce1a3bb0b0677a2612e7ff;p=m6w6%2Fext-http * try the direct way --- diff --git a/http_curl_api.c b/http_curl_api.c index 7f0638f..f1ec92c 100644 --- a/http_curl_api.c +++ b/http_curl_api.c @@ -31,10 +31,6 @@ #include "php_http_curl_api.h" #include "php_http_std_defs.h" -#ifdef ZEND_ENGINE_2 -# include "ext/standard/php_http.h" -#endif - #include "phpstr/phpstr.h" ZEND_DECLARE_MODULE_GLOBALS(http) diff --git a/php_http.h b/php_http.h index fd925f6..8294b13 100644 --- a/php_http.h +++ b/php_http.h @@ -56,7 +56,7 @@ typedef struct { } http_request_object; typedef enum { - HTTP_GET, + HTTP_GET = 1, HTTP_HEAD, HTTP_POST, } http_request_method; diff --git a/phpstr/phpstr.h b/phpstr/phpstr.h index 50d9c28..bd749d6 100644 --- a/phpstr/phpstr.h +++ b/phpstr/phpstr.h @@ -35,21 +35,19 @@ RETVAL_STRINGL((STR)->data, (STR)->used, (dup)); \ FREE_PHPSTR((free), (STR)); -struct _phpstr { +typedef struct { size_t size; char *data; size_t used; size_t free; -}; -typedef struct _phpstr phpstr; +} phpstr; -enum _phpstr_free { +typedef enum { PHPSTR_FREE_NOT = 0, PHPSTR_FREE_PTR, /* efree() */ PHPSTR_FREE_VAL, /* phpstr_dtor() */ PHPSTR_FREE_ALL /* phpstr_free() */ -}; -typedef enum _phpstr_free phpstr_free_t; +} phpstr_free_t; #define PHPSTR_ALL_FREE(STR) PHPSTR_FREE_ALL,(STR) #define PHPSTR_PTR_FREE(STR) PHPSTR_FREE_PTR,(STR)