summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIlia Alshanetsky <iliaa@php.net>2006-05-09 22:00:08 +0000
committerIlia Alshanetsky <iliaa@php.net>2006-05-09 22:00:08 +0000
commit57184454e9e3ccecb2b55dc71cd7dc1aa65a3ad3 (patch)
tree85ae5bb099fbe25a2cdefd3e7f9bfb35b458c299
parent5a8b4e72ce918f4290eb79714208f300774746bf (diff)
downloadphp-git-57184454e9e3ccecb2b55dc71cd7dc1aa65a3ad3.tar.gz
Fixed bug #37376 (fastcgi.c compile fail with gcc 2.95.4).
-rw-r--r--NEWS1
-rw-r--r--sapi/cgi/fastcgi.c12
2 files changed, 8 insertions, 5 deletions
diff --git a/NEWS b/NEWS
index 6d9475d2e8..d43e118421 100644
--- a/NEWS
+++ b/NEWS
@@ -6,6 +6,7 @@ PHP NEWS
- Added support for Apache 2.2 handler in the Windows distro. (Edin)
- Added pg_field_table() function. (Edin)
- Add implementation of curl_multi_info_read (Brian)
+- Fixed bug #37376 (fastcgi.c compile fail with gcc 2.95.4). (Ilia)
- Fixed bug #37348 (make PEAR install ignore open_basedir). (Ilia)
- Fixed bug #37313 (sigemptyset() used without including <signal.h>).
(jdolecek)
diff --git a/sapi/cgi/fastcgi.c b/sapi/cgi/fastcgi.c
index 0fc16d5671..94a2cf67ca 100644
--- a/sapi/cgi/fastcgi.c
+++ b/sapi/cgi/fastcgi.c
@@ -669,12 +669,14 @@ int fcgi_accept_request(fcgi_request *req)
}
FCGI_UNLOCK(req->listen_socket);
#else
- sa_t sa;
- socklen_t len = sizeof(sa);
+ {
+ sa_t sa;
+ socklen_t len = sizeof(sa);
- FCGI_LOCK(req->listen_socket);
- req->fd = accept(req->listen_socket, (struct sockaddr *)&sa, &len);
- FCGI_UNLOCK(req->listen_socket);
+ FCGI_LOCK(req->listen_socket);
+ req->fd = accept(req->listen_socket, (struct sockaddr *)&sa, &len);
+ FCGI_UNLOCK(req->listen_socket);
+ }
#endif
if (req->fd < 0 && (in_shutdown || errno != EINTR)) {