upstream patch (5.4.13) for 2 failed tests
This commit is contained in:
parent
61028a22b2
commit
4422fef66d
@ -1,19 +1,33 @@
|
|||||||
diff -up php-5.4.11/sapi/cli/php_cli_server.c.select php-5.4.11/sapi/cli/php_cli_server.c
|
From 0cea9e6843384c6c0ebb52047c42b0431a4f5660 Mon Sep 17 00:00:00 2001
|
||||||
--- php-5.4.11/sapi/cli/php_cli_server.c.select 2013-01-16 02:10:30.000000000 -0500
|
From: Remi Collet <remi@php.net>
|
||||||
+++ php-5.4.11/sapi/cli/php_cli_server.c 2013-02-01 12:12:04.650950760 -0500
|
Date: Fri, 1 Feb 2013 19:23:25 +0100
|
||||||
@@ -710,10 +710,9 @@ static void php_cli_server_poller_remove
|
Subject: [PATCH] Fixed bug #64128 buit-in web server is broken on ppc64.
|
||||||
|
|
||||||
|
fdset management using bit operator is broken on non-x86 arch
|
||||||
|
and cause built-in server the enter an infinite loop of "select"
|
||||||
|
and never handle any request.
|
||||||
|
---
|
||||||
|
NEWS | 3 +++
|
||||||
|
sapi/cli/php_cli_server.c | 30 +++++++++++++-----------------
|
||||||
|
2 files changed, 16 insertions(+), 17 deletions(-)
|
||||||
|
|
||||||
|
diff --git a/sapi/cli/php_cli_server.c b/sapi/cli/php_cli_server.c
|
||||||
|
index 28aba19..6a4e7c5 100644
|
||||||
|
--- a/sapi/cli/php_cli_server.c
|
||||||
|
+++ b/sapi/cli/php_cli_server.c
|
||||||
|
@@ -710,10 +710,9 @@ static void php_cli_server_poller_remove(php_cli_server_poller *poller, int mode
|
||||||
if (fd == poller->max_fd) {
|
if (fd == poller->max_fd) {
|
||||||
while (fd > 0) {
|
while (fd > 0) {
|
||||||
fd--;
|
fd--;
|
||||||
- if (((unsigned int *)&poller->rfds)[fd / (8 * sizeof(unsigned int))] || ((unsigned int *)&poller->wfds)[fd / (8 * sizeof(unsigned int))]) {
|
- if (((unsigned int *)&poller->rfds)[fd / (8 * sizeof(unsigned int))] || ((unsigned int *)&poller->wfds)[fd / (8 * sizeof(unsigned int))]) {
|
||||||
+ if (PHP_SAFE_FD_ISSET(fd, &poller->rfds) || PHP_SAFE_FD_ISSET(fd, &poller->wfds)) {
|
+ if (PHP_SAFE_FD_ISSET(fd, &poller->rfds) || PHP_SAFE_FD_ISSET(fd, &poller->wfds)) {
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
- fd -= fd % (8 * sizeof(unsigned int));
|
- fd -= fd % (8 * sizeof(unsigned int));
|
||||||
}
|
}
|
||||||
poller->max_fd = fd;
|
poller->max_fd = fd;
|
||||||
}
|
}
|
||||||
@@ -772,23 +771,20 @@ static int php_cli_server_poller_iter_on
|
@@ -772,23 +771,20 @@ static int php_cli_server_poller_iter_on_active(php_cli_server_poller *poller, v
|
||||||
}
|
}
|
||||||
|
|
||||||
#else
|
#else
|
||||||
@ -37,15 +51,18 @@ diff -up php-5.4.11/sapi/cli/php_cli_server.c.select php-5.4.11/sapi/cli/php_cli
|
|||||||
+ if (PHP_SAFE_FD_ISSET(fd, &poller->active.rfds)) {
|
+ if (PHP_SAFE_FD_ISSET(fd, &poller->active.rfds)) {
|
||||||
+ if (SUCCESS != callback(opaque, fd, POLLIN)) {
|
+ if (SUCCESS != callback(opaque, fd, POLLIN)) {
|
||||||
+ retval = FAILURE;
|
+ retval = FAILURE;
|
||||||
+ }
|
+ }
|
||||||
+ }
|
+ }
|
||||||
+ if (PHP_SAFE_FD_ISSET(fd, &poller->active.wfds)) {
|
+ if (PHP_SAFE_FD_ISSET(fd, &poller->active.wfds)) {
|
||||||
+ if (SUCCESS != callback(opaque, fd, POLLOUT)) {
|
+ if (SUCCESS != callback(opaque, fd, POLLOUT)) {
|
||||||
+ retval = FAILURE;
|
+ retval = FAILURE;
|
||||||
+ }
|
+ }
|
||||||
}
|
}
|
||||||
- pr++;
|
- pr++;
|
||||||
- pw++;
|
- pw++;
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
return retval;
|
return retval;
|
||||||
|
--
|
||||||
|
1.7.11.5
|
||||||
|
|
||||||
|
53
php-5.4.11-sockets.patch
Normal file
53
php-5.4.11-sockets.patch
Normal file
@ -0,0 +1,53 @@
|
|||||||
|
From f7362232f47a9fcaf0162087dbbbdb0b4562b59d Mon Sep 17 00:00:00 2001
|
||||||
|
From: Remi Collet <remi@php.net>
|
||||||
|
Date: Thu, 31 Jan 2013 14:22:56 +0100
|
||||||
|
Subject: [PATCH] Fix failed test: sys_errlist[116] have changed on recent
|
||||||
|
glibc (Fedora 18) old: Stale NFS file handle new: Stale
|
||||||
|
file handle
|
||||||
|
|
||||||
|
---
|
||||||
|
ext/sockets/tests/socket_strerror.phpt | 2 +-
|
||||||
|
1 file changed, 1 insertion(+), 1 deletion(-)
|
||||||
|
|
||||||
|
diff --git a/ext/sockets/tests/socket_strerror.phpt b/ext/sockets/tests/socket_strerror.phpt
|
||||||
|
index 7985fad..fb9925e 100644
|
||||||
|
--- a/ext/sockets/tests/socket_strerror.phpt
|
||||||
|
+++ b/ext/sockets/tests/socket_strerror.phpt
|
||||||
|
@@ -138,7 +138,7 @@ string(12) "Host is down"
|
||||||
|
string(16) "No route to host"
|
||||||
|
string(29) "Operation already in progress"
|
||||||
|
string(25) "Operation now in progress"
|
||||||
|
-string(21) "Stale NFS file handle"
|
||||||
|
+string(%d) "Stale%sfile handle"
|
||||||
|
string(24) "Structure needs cleaning"
|
||||||
|
string(27) "Not a XENIX named type file"
|
||||||
|
string(29) "No XENIX semaphores available"
|
||||||
|
--
|
||||||
|
1.7.11.5
|
||||||
|
|
||||||
|
From 9d75bf35e96bfc5c8d629ecef6807a90b4c98be7 Mon Sep 17 00:00:00 2001
|
||||||
|
From: Remi Collet <remi@php.net>
|
||||||
|
Date: Thu, 31 Jan 2013 14:38:39 +0100
|
||||||
|
Subject: [PATCH] Mark this test as requiring internet connecion.
|
||||||
|
|
||||||
|
---
|
||||||
|
ext/sockets/tests/socket_bind.phpt | 3 +++
|
||||||
|
1 file changed, 3 insertions(+)
|
||||||
|
|
||||||
|
diff --git a/ext/sockets/tests/socket_bind.phpt b/ext/sockets/tests/socket_bind.phpt
|
||||||
|
index 15181e6..7ea2df8 100644
|
||||||
|
--- a/ext/sockets/tests/socket_bind.phpt
|
||||||
|
+++ b/ext/sockets/tests/socket_bind.phpt
|
||||||
|
@@ -8,6 +8,9 @@ fa@php.net
|
||||||
|
if (!extension_loaded('sockets')) {
|
||||||
|
die('skip - sockets extension not available.');
|
||||||
|
}
|
||||||
|
+ if (getenv("SKIP_ONLINE_TESTS")) {
|
||||||
|
+ die("skip test requiring internet connection");
|
||||||
|
+ }
|
||||||
|
?>
|
||||||
|
--FILE--
|
||||||
|
<?php
|
||||||
|
--
|
||||||
|
1.7.11.5
|
||||||
|
|
8
php.spec
8
php.spec
@ -58,7 +58,7 @@
|
|||||||
Summary: PHP scripting language for creating dynamic web sites
|
Summary: PHP scripting language for creating dynamic web sites
|
||||||
Name: php
|
Name: php
|
||||||
Version: 5.4.12
|
Version: 5.4.12
|
||||||
Release: 0.2.RC1%{?dist}
|
Release: 0.3.RC1%{?dist}
|
||||||
# All files licensed under PHP version 3.01, except
|
# All files licensed under PHP version 3.01, except
|
||||||
# Zend is licensed under Zend
|
# Zend is licensed under Zend
|
||||||
# TSRM is licensed under BSD
|
# TSRM is licensed under BSD
|
||||||
@ -106,6 +106,8 @@ Patch47: php-5.4.9-phpinfo.patch
|
|||||||
|
|
||||||
|
|
||||||
# Fixes for tests
|
# Fixes for tests
|
||||||
|
Patch50: php-5.4.11-sockets.patch
|
||||||
|
|
||||||
|
|
||||||
BuildRequires: bzip2-devel, curl-devel >= 7.9, %{db_devel}, gmp-devel
|
BuildRequires: bzip2-devel, curl-devel >= 7.9, %{db_devel}, gmp-devel
|
||||||
BuildRequires: httpd-devel >= 2.0.46-1, pam-devel
|
BuildRequires: httpd-devel >= 2.0.46-1, pam-devel
|
||||||
@ -674,6 +676,7 @@ support for using the enchant library to PHP.
|
|||||||
%endif
|
%endif
|
||||||
%patch46 -p1 -b .fixheader
|
%patch46 -p1 -b .fixheader
|
||||||
%patch47 -p1 -b .phpinfo
|
%patch47 -p1 -b .phpinfo
|
||||||
|
%patch50 -p1 -b .sockets
|
||||||
|
|
||||||
# Prevent %%doc confusion over LICENSE files
|
# Prevent %%doc confusion over LICENSE files
|
||||||
cp Zend/LICENSE Zend/ZEND_LICENSE
|
cp Zend/LICENSE Zend/ZEND_LICENSE
|
||||||
@ -1406,6 +1409,9 @@ fi
|
|||||||
|
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Mon Feb 4 2013 Remi Collet <rcollet@redhat.com> 5.4.12-0.3.RC1
|
||||||
|
- upstream patch (5.4.13) for 2 failed tests
|
||||||
|
|
||||||
* Fri Feb 1 2013 Remi Collet <rcollet@redhat.com> 5.4.12-0.2.RC1
|
* Fri Feb 1 2013 Remi Collet <rcollet@redhat.com> 5.4.12-0.2.RC1
|
||||||
- fix buit-in web server on ppc64 (fdset usage)
|
- fix buit-in web server on ppc64 (fdset usage)
|
||||||
https://bugs.php.net/64128
|
https://bugs.php.net/64128
|
||||||
|
Loading…
x
Reference in New Issue
Block a user