From: Michael Wallner Date: Mon, 21 Sep 2020 07:42:30 +0000 (+0200) Subject: drop dep on ext-propro (dysfunctional with PHP 8) X-Git-Tag: v4.0.0beta1~4 X-Git-Url: https://git.m6w6.name/?a=commitdiff_plain;h=018096825617afa428c9c17f83b1ad3f3f3f96e5;p=m6w6%2Fext-http drop dep on ext-propro (dysfunctional with PHP 8) --- diff --git a/.travis.yml b/.travis.yml index 1f1f111..10fef4c 100644 --- a/.travis.yml +++ b/.travis.yml @@ -47,11 +47,9 @@ install: if test "$PHP" = master; then \ make -f travis/pecl/Makefile reconf; \ make -f travis/pecl/Makefile pecl-rm pecl-clean PECL=ext-raphf.git:raphf:master; \ - make -f travis/pecl/Makefile pecl-rm pecl-clean PECL=ext-propro.git:propro:master; \ fi - make -f travis/pecl/Makefile php || make -f travis/pecl/Makefile clean php - make -f travis/pecl/Makefile pecl PECL=ext-raphf.git:raphf:master - - make -f travis/pecl/Makefile pecl PECL=ext-propro.git:propro:master - | if test -n "$PECLs"; then \ IFS=$','; \ diff --git a/config.w32 b/config.w32 index 68006df..04c1f75 100644 --- a/config.w32 +++ b/config.w32 @@ -125,7 +125,6 @@ if (PHP_HTTP != "no") { CHECK_LIB("libcrypto.lib;libeay32.lib", "http", PHP_HTTP) && CHECK_LIB("crypt32.lib;libeay32.lib", "http", PHP_HTTP) && CHECK_LIB("zlib.lib;zlib_a.lib", "http", PHP_HTTP) && - ADD_EXTENSION_DEP("http", "propro", true) && ADD_EXTENSION_DEP("http", "raphf", true) && CHECK_LIB("winmm.lib", "http", PHP_HTTP)) { AC_DEFINE("PHP_HTTP_HAVE_LIBCURL", 1, "Have CURL library"); diff --git a/config9.m4 b/config9.m4 index 897b92f..66a4ec5 100644 --- a/config9.m4 +++ b/config9.m4 @@ -161,11 +161,6 @@ if test "$PHP_HTTP" != "no"; then ], [ AC_MSG_ERROR([please install and enable pecl/raphf]) ]) - PECL_HAVE_PHP_EXT([propro], [ - PECL_HAVE_PHP_EXT_HEADER([propro]) - ], [ - AC_MSG_ERROR([please install and enable pecl/propro]) - ]) PECL_HAVE_PHP_EXT([hash]) PECL_HAVE_PHP_EXT([iconv]) @@ -196,7 +191,6 @@ if test "$PHP_HTTP" != "no"; then fi fi PHP_ADD_EXTENSION_DEP([http], [raphf], true) - PHP_ADD_EXTENSION_DEP([http], [propro], true) PHP_SUBST(PECL_VAR([HEADERS])) PHP_SUBST(PECL_VAR([SOURCES])) diff --git a/package.xml b/package.xml index 866ba0c..7cdebcc 100644 --- a/package.xml +++ b/package.xml @@ -31,10 +31,10 @@ https://mdref.m6w6.name/http mike@php.net yes - 2019-10-29 + 2020-09-21 - 3.2.3 - 3.2.0 + 4.0.0dev + 4.0.0 stable @@ -42,7 +42,7 @@ https://mdref.m6w6.name/http BSD-2-Clause @@ -386,7 +386,7 @@ https://mdref.m6w6.name/http - 7.0.0 + 8.0.0 1.4.1 @@ -397,12 +397,6 @@ https://mdref.m6w6.name/http 2.0.0dev raphf - - propro - pecl.php.net - 2.0.0dev - propro - hash diff --git a/php_http.h b/php_http.h index 19d67f9..be3237e 100644 --- a/php_http.h +++ b/php_http.h @@ -13,7 +13,7 @@ #ifndef PHP_EXT_HTTP_H #define PHP_EXT_HTTP_H -#define PHP_PECL_HTTP_VERSION "3.2.3" +#define PHP_PECL_HTTP_VERSION "4.0.0dev" extern zend_module_entry http_module_entry; #define phpext_http_ptr &http_module_entry diff --git a/scripts/check_package-xml.php b/scripts/check_package-xml.php index e422c6a..4ff8e4a 100755 --- a/scripts/check_package-xml.php +++ b/scripts/check_package-xml.php @@ -33,7 +33,7 @@ if (($xml = simplexml_load_file($file))) { } } else { $base = basename($file); - if ($base{0} !== ".") { + if ($base[0] !== ".") { array_push($dirs, $file); } } diff --git a/scripts/gen_travis_yml.php b/scripts/gen_travis_yml.php index 71a855b..c0adebe 100755 --- a/scripts/gen_travis_yml.php +++ b/scripts/gen_travis_yml.php @@ -95,11 +95,9 @@ install: if test "$PHP" = master; then \ make -f travis/pecl/Makefile reconf; \ make -f travis/pecl/Makefile pecl-rm pecl-clean PECL=ext-raphf.git:raphf:master; \ - make -f travis/pecl/Makefile pecl-rm pecl-clean PECL=ext-propro.git:propro:master; \ fi - make -f travis/pecl/Makefile php || make -f travis/pecl/Makefile clean php - make -f travis/pecl/Makefile pecl PECL=ext-raphf.git:raphf:master - - make -f travis/pecl/Makefile pecl PECL=ext-propro.git:propro:master - | if test -n "$PECLs"; then \ IFS=$','; \ diff --git a/src/php_http.c b/src/php_http.c index 498a224..8cf8126 100644 --- a/src/php_http.c +++ b/src/php_http.c @@ -58,7 +58,6 @@ PHP_MINFO_FUNCTION(http); static zend_module_dep http_module_deps[] = { ZEND_MOD_REQUIRED("raphf") - ZEND_MOD_REQUIRED("propro") ZEND_MOD_REQUIRED("spl") #if PHP_HTTP_HAVE_HASH ZEND_MOD_REQUIRED("hash") diff --git a/src/php_http_api.h b/src/php_http_api.h index bca57f1..a4058af 100644 --- a/src/php_http_api.h +++ b/src/php_http_api.h @@ -32,7 +32,6 @@ #include "SAPI.h" #include "ext/raphf/php_raphf_api.h" -#include "ext/propro/php_propro_api.h" #include "ext/standard/php_string.h" #include "ext/spl/spl_iterators.h" #include "ext/date/php_date.h" diff --git a/src/php_http_message.c b/src/php_http_message.c index 371ecb7..2cce701 100644 --- a/src/php_http_message.c +++ b/src/php_http_message.c @@ -911,20 +911,9 @@ static zval *php_http_message_object_read_prop(zval *object, zval *member, int t return_value = zend_get_std_object_handlers()->read_property(object, member, type, cache_slot, tmp); if (handler && handler->read) { - if (type == BP_VAR_R || type == BP_VAR_IS) { - php_http_message_object_t *obj = PHP_HTTP_OBJ(NULL, object); + php_http_message_object_t *obj = PHP_HTTP_OBJ(NULL, object); - handler->read(obj, return_value); - } else { - php_property_proxy_t *proxy; - php_property_proxy_object_t *proxy_obj; - - proxy = php_property_proxy_init(object, member_name); - proxy_obj = php_property_proxy_object_new_ex(NULL, proxy); - - ZVAL_OBJ(tmp, &proxy_obj->zo); - return_value = tmp; - } + handler->read(obj, return_value); } zend_string_release(member_name); diff --git a/tests/helper/server.inc b/tests/helper/server.inc index 9ca96cd..f203ed6 100644 --- a/tests/helper/server.inc +++ b/tests/helper/server.inc @@ -24,7 +24,7 @@ if ($php) { define("PHP_BIN", PHP_BINDIR.DIRECTORY_SEPARATOR."php"); } -foreach (array("raphf", "propro", "http") as $ext) { +foreach (array("raphf", "http") as $ext) { if (!extension_loaded($ext)) { dl(ext_lib_name($ext)); } @@ -131,7 +131,7 @@ function server($handler, $cb) { $args[] = $argList[$i]; } } - foreach (['raphf', 'propro', 'http'] as $ext) { + foreach (['raphf', 'http'] as $ext) { if (null !== $arg = get_extension_load_arg(PHP_BIN, $args, $ext)) { $args[] = $arg; }