mirror of
https://github.com/php/php-src.git
synced 2025-08-16 05:58:45 +02:00
Merge branch 'PHP-7.2' into PHP-7.3
This commit is contained in:
commit
b394654c1e
3 changed files with 7 additions and 0 deletions
4
NEWS
4
NEWS
|
@ -18,6 +18,10 @@ PHP NEWS
|
||||||
. Fixed bug #78015 (Incorrect evaluation of expressions involving partials
|
. Fixed bug #78015 (Incorrect evaluation of expressions involving partials
|
||||||
arrays in SCCP). (Nikita)
|
arrays in SCCP). (Nikita)
|
||||||
|
|
||||||
|
- Sockets:
|
||||||
|
. Fixed bug #78038 (Socket_select fails when resource array contains
|
||||||
|
references). (Nikita)
|
||||||
|
|
||||||
16 May 2019, PHP 7.3.6RC1
|
16 May 2019, PHP 7.3.6RC1
|
||||||
|
|
||||||
- cURL:
|
- cURL:
|
||||||
|
|
|
@ -898,6 +898,7 @@ static int php_sock_array_to_fd_set(zval *sock_array, fd_set *fds, PHP_SOCKET *m
|
||||||
if (Z_TYPE_P(sock_array) != IS_ARRAY) return 0;
|
if (Z_TYPE_P(sock_array) != IS_ARRAY) return 0;
|
||||||
|
|
||||||
ZEND_HASH_FOREACH_VAL(Z_ARRVAL_P(sock_array), element) {
|
ZEND_HASH_FOREACH_VAL(Z_ARRVAL_P(sock_array), element) {
|
||||||
|
ZVAL_DEREF(element);
|
||||||
php_sock = (php_socket*) zend_fetch_resource_ex(element, le_socket_name, le_socket);
|
php_sock = (php_socket*) zend_fetch_resource_ex(element, le_socket_name, le_socket);
|
||||||
if (!php_sock) continue; /* If element is not a resource, skip it */
|
if (!php_sock) continue; /* If element is not a resource, skip it */
|
||||||
|
|
||||||
|
@ -926,6 +927,7 @@ static int php_sock_array_from_fd_set(zval *sock_array, fd_set *fds) /* {{{ */
|
||||||
|
|
||||||
array_init(&new_hash);
|
array_init(&new_hash);
|
||||||
ZEND_HASH_FOREACH_KEY_VAL(Z_ARRVAL_P(sock_array), num_key, key, element) {
|
ZEND_HASH_FOREACH_KEY_VAL(Z_ARRVAL_P(sock_array), num_key, key, element) {
|
||||||
|
ZVAL_DEREF(element);
|
||||||
php_sock = (php_socket*) zend_fetch_resource_ex(element, le_socket_name, le_socket);
|
php_sock = (php_socket*) zend_fetch_resource_ex(element, le_socket_name, le_socket);
|
||||||
if (!php_sock) continue; /* If element is not a resource, skip it */
|
if (!php_sock) continue; /* If element is not a resource, skip it */
|
||||||
|
|
||||||
|
|
|
@ -17,6 +17,7 @@ socket_create_pair($domain, SOCK_STREAM, 0, $sockets);
|
||||||
|
|
||||||
$write = null;
|
$write = null;
|
||||||
$except = null;
|
$except = null;
|
||||||
|
$ref =& $sockets[0]; // bug #78038
|
||||||
var_dump(socket_select($sockets, $write, $except, 0));
|
var_dump(socket_select($sockets, $write, $except, 0));
|
||||||
--EXPECT--
|
--EXPECT--
|
||||||
int(0)
|
int(0)
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue