]> git.ipfire.org Git - thirdparty/haproxy.git/commitdiff
[BUG] process_response must not enable the read FD
authorWilly Tarreau <w@1wt.eu>
Sat, 16 Aug 2008 14:11:07 +0000 (16:11 +0200)
committerWilly Tarreau <w@1wt.eu>
Sat, 16 Aug 2008 14:11:07 +0000 (16:11 +0200)
Since the separation of TCP and HTTP state machines, the HTTP
code must not play anymore with the file descriptor status
without checking if they are closed. Remains of such practice
have caused busy loops under some circumstances (mainly when
client closed during headers response).

src/proto_http.c

index 6121a93c165a39a36dcb38ae2a2b5226d047d7b5..552f7e5bf68d98f0beeff47fa547b79412894652 100644 (file)
@@ -2570,17 +2570,6 @@ int process_response(struct session *t)
                        }
                }
 
-
-               if ((rep->l < rep->rlim - rep->data) && !tick_isset(rep->rex)) {
-                       EV_FD_COND_S(t->srv_fd, DIR_RD);
-                       /* fd in DIR_RD was disabled, perhaps because of a previous buffer
-                        * full. We cannot loop here since stream_sock_read will disable it only if
-                        * rep->l == rlim-data
-                        */
-                       rep->rex = tick_add_ifset(now_ms, t->be->timeout.server);
-               }
-
-
                /*
                 * Now we quickly check if we have found a full valid response.
                 * If not so, we check the FD and buffer states before leaving.