]> git.ipfire.org Git - thirdparty/haproxy.git/commitdiff
[OPTIM] remove useless fd_set(read) upon shutdown(write)
authorWilly Tarreau <w@1wt.eu>
Wed, 27 Aug 2008 13:19:25 +0000 (15:19 +0200)
committerWilly Tarreau <w@1wt.eu>
Sun, 2 Nov 2008 09:19:05 +0000 (10:19 +0100)
Those old tricks are no longer needed and are overwritten
anyway. Remove them.

src/proto_http.c

index c065fda21b038b9d85aa1366ccb17bcc19bdeed4..f4581226b5f0c563ed748d700fd7356ac1036371 100644 (file)
@@ -3247,10 +3247,6 @@ int process_cli(struct session *t)
                        if (!(req->flags & BF_SHUTR)) {
                                EV_FD_CLR(t->cli_fd, DIR_WR);
                                shutdown(t->cli_fd, SHUT_WR);
-                               /* We must ensure that the read part is still alive when switching to shutw */
-                               /* FIXME: is this still true ? */
-                               EV_FD_SET(t->cli_fd, DIR_RD);
-                               req->rex = tick_add_ifset(now_ms, t->fe->timeout.client);
                                trace_term(t, TT_HTTP_CLI_4);
                        } else {
                                fd_delete(t->cli_fd);
@@ -3291,10 +3287,6 @@ int process_cli(struct session *t)
                        if (!(req->flags & BF_SHUTR)) {
                                EV_FD_CLR(t->cli_fd, DIR_WR);
                                shutdown(t->cli_fd, SHUT_WR);
-                               /* We must ensure that the read part is still alive when switching to shutw */
-                               /* FIXME: is this still true ? */
-                               EV_FD_SET(t->cli_fd, DIR_RD);
-                               req->rex = tick_add_ifset(now_ms, t->fe->timeout.client);
                                trace_term(t, TT_HTTP_CLI_8);
                        } else {
                                fd_delete(t->cli_fd);
@@ -3949,10 +3941,6 @@ int process_srv_data(struct session *t)
                        trace_term(t, TT_HTTP_SRV_9);
                        EV_FD_CLR(fd, DIR_WR);
                        shutdown(fd, SHUT_WR);
-                       /* We must ensure that the read part is still alive when switching to shutw */
-                       /* FIXME: is this still true ? */
-                       EV_FD_SET(fd, DIR_RD);
-                       rep->rex = tick_add_ifset(now_ms, t->be->timeout.server);
                } else {
                        trace_term(t, TT_HTTP_SRV_10);
                        fd_delete(fd);
@@ -4012,10 +4000,6 @@ int process_srv_data(struct session *t)
                        trace_term(t, TT_HTTP_SRV_13);
                        EV_FD_CLR(fd, DIR_WR);
                        shutdown(fd, SHUT_WR);
-                       /* We must ensure that the read part is still alive when switching to shutw */
-                       /* FIXME: is this still needed ? */
-                       EV_FD_SET(fd, DIR_RD);
-                       rep->rex = tick_add_ifset(now_ms, t->be->timeout.server);
                } else {
                        trace_term(t, TT_HTTP_SRV_14);
                        fd_delete(fd);