summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRemi Collet <remi@remirepo.net>2019-07-26 09:45:25 +0200
committerRemi Collet <remi@remirepo.net>2019-07-26 09:45:25 +0200
commitcb693c55fc2a2e4e6cc9ca94f6328eee8c7c85bb (patch)
tree7b9dd8bdc87c3f693e7d9e1f45b9097423d4f7b1
parente8bf252eb7e1aa23b49dcfb638e1ff4e59d64b98 (diff)
v4.4.2
-rw-r--r--2707.patch145
-rw-r--r--PHPINFO4
-rw-r--r--REFLECTION16
-rw-r--r--php-pecl-swoole4.spec12
4 files changed, 19 insertions, 158 deletions
diff --git a/2707.patch b/2707.patch
deleted file mode 100644
index 4614be2..0000000
--- a/2707.patch
+++ /dev/null
@@ -1,145 +0,0 @@
-From b7514a7615b01aa20e0be73f7e13655a68fd61ea Mon Sep 17 00:00:00 2001
-From: Remi Collet <remi@remirepo.net>
-Date: Tue, 23 Jul 2019 14:37:46 +0200
-Subject: [PATCH] fix for stream changes in 7.4.0beta1
-
----
- swoole_runtime.cc | 17 +++++++++++++++++
- thirdparty/php/streams/plain_wrapper.c | 21 +++++++++++++++++++++
- 2 files changed, 38 insertions(+)
-
-diff --git a/swoole_runtime.cc b/swoole_runtime.cc
-index eb6664a61..dc0fb9ad3 100644
---- a/swoole_runtime.cc
-+++ b/swoole_runtime.cc
-@@ -38,8 +38,13 @@ static PHP_FUNCTION(swoole_user_func_handler);
- }
-
- static int socket_set_option(php_stream *stream, int option, int value, void *ptrparam);
-+#if PHP_VERSION_ID < 70400
- static size_t socket_read(php_stream *stream, char *buf, size_t count);
- static size_t socket_write(php_stream *stream, const char *buf, size_t count);
-+#else
-+static ssize_t socket_read(php_stream *stream, char *buf, size_t count);
-+static ssize_t socket_write(php_stream *stream, const char *buf, size_t count);
-+#endif
- static int socket_flush(php_stream *stream);
- static int socket_close(php_stream *stream, int close_handle);
- static int socket_stat(php_stream *stream, php_stream_statbuf *ssb);
-@@ -259,7 +264,11 @@ static inline char *parse_ip_address_ex(const char *str, size_t str_len, int *po
- return host;
- }
-
-+#if PHP_VERSION_ID < 70400
- static size_t socket_write(php_stream *stream, const char *buf, size_t count)
-+#else
-+static ssize_t socket_write(php_stream *stream, const char *buf, size_t count)
-+#endif
- {
- php_swoole_netstream_data_t *abstract = (php_swoole_netstream_data_t *) stream->abstract;
- if (UNEXPECTED(!abstract))
-@@ -277,15 +286,21 @@ static size_t socket_write(php_stream *stream, const char *buf, size_t count)
- {
- php_stream_notify_progress_increment(PHP_STREAM_CONTEXT(stream), didwrite, 0);
- }
-+#if PHP_VERSION_ID < 70400
- if (didwrite < 0)
- {
- didwrite = 0;
- }
-+#endif
-
- return didwrite;
- }
-
-+#if PHP_VERSION_ID < 70400
- static size_t socket_read(php_stream *stream, char *buf, size_t count)
-+#else
-+static ssize_t socket_read(php_stream *stream, char *buf, size_t count)
-+#endif
- {
- php_swoole_netstream_data_t *abstract = (php_swoole_netstream_data_t *) stream->abstract;
- if (UNEXPECTED(!abstract))
-@@ -309,10 +324,12 @@ static size_t socket_read(php_stream *stream, char *buf, size_t count)
- php_stream_notify_progress_increment(PHP_STREAM_CONTEXT(stream), nr_bytes, 0);
- }
-
-+#if PHP_VERSION_ID < 70400
- if (nr_bytes < 0)
- {
- nr_bytes = 0;
- }
-+#endif
-
- return nr_bytes;
- }
-diff --git a/thirdparty/php/streams/plain_wrapper.c b/thirdparty/php/streams/plain_wrapper.c
-index f4ad4ed9b..6751b6212 100644
---- a/thirdparty/php/streams/plain_wrapper.c
-+++ b/thirdparty/php/streams/plain_wrapper.c
-@@ -59,8 +59,13 @@ extern int php_get_gid_by_name(const char *name, gid_t *gid);
- # define PLAIN_WRAP_BUF_SIZE(st) (st)
- #endif
-
-+#if PHP_VERSION_ID < 70400
- static size_t php_stdiop_write(php_stream *stream, const char *buf, size_t count);
- static size_t php_stdiop_read(php_stream *stream, char *buf, size_t count);
-+#else
-+static ssize_t php_stdiop_write(php_stream *stream, const char *buf, size_t count);
-+static ssize_t php_stdiop_read(php_stream *stream, char *buf, size_t count);
-+#endif
- static int sw_php_stdiop_close(php_stream *stream, int close_handle);
- static int php_stdiop_stat(php_stream *stream, php_stream_statbuf *ssb);
- static int php_stdiop_flush(php_stream *stream);
-@@ -216,7 +221,11 @@ static php_stream *_sw_php_stream_fopen_from_fd_int(int fd, const char *mode, co
- return php_stream_alloc_rel(&sw_php_stream_stdio_ops, self, persistent_id, mode);
- }
-
-+#if PHP_VERSION_ID < 70400
- static size_t php_stdiop_write(php_stream *stream, const char *buf, size_t count)
-+#else
-+static ssize_t php_stdiop_write(php_stream *stream, const char *buf, size_t count)
-+#endif
- {
- php_stdio_stream_data *data = (php_stdio_stream_data*) stream->abstract;
-
-@@ -225,11 +234,15 @@ static size_t php_stdiop_write(php_stream *stream, const char *buf, size_t count
- if (data->fd >= 0)
- {
- int bytes_written = write(data->fd, buf, count);
-+#if PHP_VERSION_ID < 70400
- if (bytes_written < 0)
- {
- return 0;
- }
- return (size_t) bytes_written;
-+#else
-+ return bytes_written;
-+#endif
- }
- else
- {
-@@ -237,7 +250,11 @@ static size_t php_stdiop_write(php_stream *stream, const char *buf, size_t count
- }
- }
-
-+#if PHP_VERSION_ID < 70400
- static size_t php_stdiop_read(php_stream *stream, char *buf, size_t count)
-+#else
-+static ssize_t php_stdiop_read(php_stream *stream, char *buf, size_t count)
-+#endif
- {
- php_stdio_stream_data *data = (php_stdio_stream_data*) stream->abstract;
- size_t ret;
-@@ -737,7 +754,11 @@ static int php_stdiop_set_option(php_stream *stream, int option, int value, void
- /* }}} */
-
- /* {{{ plain files opendir/readdir implementation */
-+#if PHP_VERSION_ID < 70400
- static size_t php_plain_files_dirstream_read(php_stream *stream, char *buf, size_t count)
-+#else
-+static ssize_t php_plain_files_dirstream_read(php_stream *stream, char *buf, size_t count)
-+#endif
- {
- DIR *dir = (DIR*) stream->abstract;
- struct dirent *result;
diff --git a/PHPINFO b/PHPINFO
index 5017ba4..e04de66 100644
--- a/PHPINFO
+++ b/PHPINFO
@@ -3,8 +3,8 @@ swoole
Swoole => enabled
Author => Swoole Team <team@swoole.com>
-Version => 4.4.1
-Built => Jul 16 2019 08:39:17
+Version => 4.4.2
+Built => Jul 26 2019 09:41:58
coroutine => enabled
trace_log => enabled
epoll => enabled
diff --git a/REFLECTION b/REFLECTION
index daa24a6..4e3c9e7 100644
--- a/REFLECTION
+++ b/REFLECTION
@@ -1,4 +1,4 @@
-Extension [ <persistent> extension #153 swoole version 4.4.1 ] {
+Extension [ <persistent> extension #153 swoole version 4.4.2 ] {
- INI {
Entry [ swoole.enable_coroutine <ALL> ]
@@ -22,11 +22,11 @@ Extension [ <persistent> extension #153 swoole version 4.4.1 ] {
}
- Constants [311] {
- Constant [ string SWOOLE_VERSION ] { 4.4.1 }
- Constant [ integer SWOOLE_VERSION_ID ] { 40401 }
+ Constant [ string SWOOLE_VERSION ] { 4.4.2 }
+ Constant [ integer SWOOLE_VERSION_ID ] { 40402 }
Constant [ integer SWOOLE_MAJOR_VERSION ] { 4 }
Constant [ integer SWOOLE_MINOR_VERSION ] { 4 }
- Constant [ integer SWOOLE_RELEASE_VERSION ] { 1 }
+ Constant [ integer SWOOLE_RELEASE_VERSION ] { 2 }
Constant [ string SWOOLE_EXTRA_VERSION ] { }
Constant [ boolean SWOOLE_DEBUG ] { }
Constant [ integer SWOOLE_BASE ] { 1 }
@@ -703,7 +703,7 @@ Extension [ <persistent> extension #153 swoole version 4.4.1 ] {
- Static properties [0] {
}
- - Static methods [10] {
+ - Static methods [11] {
Method [ <internal:swoole> static public method add ] {
- Parameters [4] {
@@ -774,6 +774,12 @@ Extension [ <persistent> extension #153 swoole version 4.4.1 ] {
}
}
+ Method [ <internal:swoole> static public method rshutdown ] {
+
+ - Parameters [0] {
+ }
+ }
+
Method [ <internal:swoole> static public method exit ] {
- Parameters [0] {
diff --git a/php-pecl-swoole4.spec b/php-pecl-swoole4.spec
index 04af961..29e6d16 100644
--- a/php-pecl-swoole4.spec
+++ b/php-pecl-swoole4.spec
@@ -30,16 +30,14 @@
Summary: PHP's asynchronous concurrent distributed networking framework
Name: %{?sub_prefix}php-pecl-%{pecl_name}4
-Version: 4.4.1
-Release: 2%{?dist}%{!?scl:%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')}}
+Version: 4.4.2
+Release: 1%{?dist}%{!?scl:%{!?nophptag:%(%{__php} -r 'echo ".".PHP_MAJOR_VERSION.".".PHP_MINOR_VERSION;')}}
# Extension is ASL 2.0
# Hiredis is BSD
License: ASL 2.0 and BSD
URL: http://pecl.php.net/package/%{pecl_name}
Source0: http://pecl.php.net/get/%{pecl_name}-%{version}.tgz
-Patch0: https://patch-diff.githubusercontent.com/raw/swoole/swoole-src/pull/2707.patch
-
%if 0%{?rhel} == 6
BuildRequires: devtoolset-6-toolchain
%else
@@ -162,8 +160,6 @@ sed \
cd NTS
-%patch0 -p1
-
# Sanity check, really often broken
extver=$(sed -n '/#define SWOOLE_VERSION /{s/.* "//;s/".*$//;p}' include/swoole.h)
if test "x${extver}" != "x%{version}%{?prever:-%{prever}}"; then
@@ -331,6 +327,10 @@ cd ../ZTS
%changelog
+* Fri Jul 26 2019 Remi Collet <remi@remirepo.net> - 4.4.2-1
+- update to 4.4.2
+- drop patch merged upstream
+
* Tue Jul 23 2019 Remi Collet <remi@remirepo.net> - 4.4.1-2
- rebuild for 7.4.0beta1
- add patch from https://github.com/swoole/swoole-src/pull/2707