[core] remove redundant resets of fde_ndx

after initialization, value of fde_ndx should be managed by fdevent.c
personal/stbuehler/mod-csrf
Glenn Strauss 6 years ago
parent e685ef70f1
commit a48d65c8a5

@ -2355,8 +2355,6 @@ static handler_t fcgi_write_request(server *srv, handler_ctx *hctx) {
/* all children are dead */
if (proc == NULL) {
hctx->fde_ndx = -1;
return HANDLER_ERROR;
}
@ -2381,7 +2379,6 @@ static handler_t fcgi_write_request(server *srv, handler_ctx *hctx) {
"socket failed:", strerror(errno), srv->cur_fds, srv->max_fds);
return HANDLER_ERROR;
}
hctx->fde_ndx = -1;
srv->cur_fds++;

@ -1341,7 +1341,6 @@ static handler_t proxy_write_request(server *srv, handler_ctx *hctx) {
return HANDLER_ERROR;
}
}
hctx->fde_ndx = -1;
srv->cur_fds++;
@ -1367,8 +1366,6 @@ static handler_t proxy_write_request(server *srv, handler_ctx *hctx) {
return HANDLER_WAIT_FOR_EVENT;
case -1:
/* if ECONNREFUSED choose another connection */
hctx->fde_ndx = -1;
return HANDLER_ERROR;
default:
/* everything is ok, go on */

@ -1885,7 +1885,6 @@ static handler_t scgi_write_request(server *srv, handler_ctx *hctx) {
"socket failed:", strerror(errno), srv->cur_fds, srv->max_fds);
return HANDLER_ERROR;
}
hctx->fde_ndx = -1;
srv->cur_fds++;
@ -1906,8 +1905,6 @@ static handler_t scgi_write_request(server *srv, handler_ctx *hctx) {
/* all childs are dead */
if (hctx->proc == NULL) {
hctx->fde_ndx = -1;
return HANDLER_ERROR;
}
@ -1926,8 +1923,6 @@ static handler_t scgi_write_request(server *srv, handler_ctx *hctx) {
return HANDLER_WAIT_FOR_EVENT;
case -1:
/* if ECONNREFUSED; choose another connection */
hctx->fde_ndx = -1;
return HANDLER_ERROR;
default:
/* everything is ok, go on */

Loading…
Cancel
Save