Browse Source

Fix hanging connection in mod_scgi (fixes #2024)

git-svn-id: svn://svn.lighttpd.net/lighttpd/branches/lighttpd-1.4.x@2585 152afb58-edef-0310-8abb-c4023f1b3aa9
svn/tags/lighttpd-1.4.24
Stefan Bühler 13 years ago
parent
commit
909a546abd
  1. 1
      NEWS
  2. 6
      src/mod_scgi.c

1
NEWS

@ -19,6 +19,7 @@ NEWS
* Set FD_CLOEXEC for bound sockets before pipe-logger forks (fixes #2026)
* Reset ignored signals to SIG_DFL before exec() in fastcgi/scgi (fixes #2029)
* Show "no uri specified -> 400" error only when "debug.log-request-header-on-error" is enabled (fixes #2030)
* Fix hanging connection in mod_scgi (fixes #2024)
- 1.4.23 - 2009-06-19
* Added some extra warning options in cmake and fix the resulting warnings (unused/static functions)

6
src/mod_scgi.c

@ -2312,8 +2312,8 @@ static handler_t scgi_write_request(server *srv, handler_ctx *hctx) {
chunkqueue_remove_finished_chunks(hctx->wb);
if (-1 == ret) {
if (errno == ENOTCONN) {
if (ret < 0) {
if (errno == ENOTCONN || ret == -2) {
/* the connection got dropped after accept()
*
* this is most of the time a PHP which dies
@ -2338,7 +2338,7 @@ static handler_t scgi_write_request(server *srv, handler_ctx *hctx) {
*/
log_error_write(srv, __FILE__, __LINE__, "ssosd",
"[REPORT ME] connection was dropped after accept(). reconnect() denied:",
"connection was dropped after accept(). reconnect() denied:",
"write-offset:", hctx->wb->bytes_out,
"reconnect attempts:", hctx->reconnects);

Loading…
Cancel
Save