Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Some connections were being added to the polling list twice.

  • Loading branch information...
commit 772f7795b8ebed67224bd5b2f15b7c3e2bbf9ee0 1 parent d68176a
@alobbs alobbs authored
View
2  cherokee/handler_cgi.c
@@ -98,8 +98,6 @@ read_from_cgi (cherokee_handler_cgi_base_t *cgi_base, cherokee_buffer_t *buffer)
case ret_eagain:
conn->polling_aim.fd = cgi->pipeInput;
conn->polling_aim.mode = poll_mode_read;
-
- cherokee_thread_deactive_to_polling (HANDLER_THREAD(cgi), conn);
return ret_eagain;
case ret_ok:
View
6 cherokee/handler_fcgi.c
@@ -172,12 +172,6 @@ read_from_fcgi (cherokee_handler_cgi_base_t *cgi, cherokee_buffer_t *buffer)
case ret_eagain:
conn->polling_aim.fd = fcgi->socket.socket;
conn->polling_aim.mode = poll_mode_read;
-
- ret = cherokee_thread_deactive_to_polling (HANDLER_THREAD(cgi), conn);
- if (unlikely (ret != ret_ok)) {
- cgi->got_eof = true;
- return ret_error;
- }
return ret_eagain;
case ret_ok:
View
44 cherokee/handler_proxy.c
@@ -638,11 +638,6 @@ do_connect (cherokee_handler_proxy_t *hdl)
case ret_eagain:
conn->polling_aim.fd = hdl->pconn->socket.socket;
conn->polling_aim.mode = poll_mode_write;
-
- ret = cherokee_thread_deactive_to_polling (HANDLER_THREAD(hdl), conn);
- if (ret != ret_ok) {
- return ret_deny;
- }
return ret_eagain;
default:
RET_UNKNOWN(ret);
@@ -711,13 +706,6 @@ send_post (cherokee_handler_proxy_t *hdl)
conn->polling_aim.fd = hdl->pconn->socket.socket;
conn->polling_aim.mode = poll_mode_write;
-
- ret = cherokee_thread_deactive_to_polling (HANDLER_THREAD(hdl), conn);
- if (ret != ret_ok) {
- hdl->pconn->keepalive_in = false;
- conn->error_code = http_bad_gateway;
- return ret_error;
- }
return ret_eagain;
default:
return ret_error;
@@ -759,13 +747,6 @@ send_post (cherokee_handler_proxy_t *hdl)
conn->polling_aim.fd = hdl->pconn->socket.socket;
conn->polling_aim.mode = poll_mode_write;
-
- ret = cherokee_thread_deactive_to_polling (HANDLER_THREAD(hdl), conn);
- if (ret != ret_ok) {
- hdl->pconn->keepalive_in = false;
- conn->error_code = http_bad_gateway;
- return ret_error;
- }
return ret_eagain;
default:
return ret_error;
@@ -797,13 +778,6 @@ send_post (cherokee_handler_proxy_t *hdl)
conn->polling_aim.fd = hdl->pconn->socket.socket;
conn->polling_aim.mode = poll_mode_write;
-
- ret = cherokee_thread_deactive_to_polling (HANDLER_THREAD(hdl), conn);
- if (ret != ret_ok) {
- hdl->pconn->keepalive_in = false;
- conn->error_code = http_bad_gateway;
- return ret_error;
- }
return ret_eagain;
default:
return ret_error;
@@ -857,13 +831,6 @@ send_post (cherokee_handler_proxy_t *hdl)
conn->polling_aim.fd = conn->socket.socket;
conn->polling_aim.mode = poll_mode_read;
-
- ret = cherokee_thread_deactive_to_polling (HANDLER_THREAD(hdl), conn);
- if (ret != ret_ok) {
- hdl->pconn->keepalive_in = false;
- conn->error_code = http_bad_gateway;
- return ret_error;
- }
return ret_eagain;
default:
return ret;
@@ -1163,13 +1130,6 @@ cherokee_handler_proxy_init (cherokee_handler_proxy_t *hdl)
case ret_eagain:
conn->polling_aim.fd = hdl->pconn->socket.socket;
conn->polling_aim.mode = poll_mode_read;
-
- ret = cherokee_thread_deactive_to_polling (HANDLER_THREAD(hdl), conn);
- if (ret != ret_ok) {
- hdl->pconn->keepalive_in = false;
- conn->error_code = http_bad_gateway;
- return ret_error;
- }
return ret_eagain;
case ret_eof:
case ret_error:
@@ -1715,8 +1675,6 @@ cherokee_handler_proxy_step (cherokee_handler_proxy_t *hdl,
case ret_eagain:
conn->polling_aim.fd = hdl->pconn->socket.socket;
conn->polling_aim.mode = poll_mode_read;
-
- cherokee_thread_deactive_to_polling (HANDLER_THREAD(hdl), conn);
return ret_eagain;
default:
RET_UNKNOWN(ret);
@@ -1826,8 +1784,6 @@ cherokee_handler_proxy_step (cherokee_handler_proxy_t *hdl,
if (ret_read == ret_eagain) {
conn->polling_aim.fd = hdl->pconn->socket.socket;
conn->polling_aim.mode = poll_mode_read;
-
- cherokee_thread_deactive_to_polling (HANDLER_THREAD(hdl), conn);
return ret_eagain;
}
View
2  cherokee/handler_scgi.c
@@ -148,8 +148,6 @@ read_from_scgi (cherokee_handler_cgi_base_t *cgi_base, cherokee_buffer_t *buffer
case ret_eagain:
conn->polling_aim.fd = scgi->socket.socket;
conn->polling_aim.mode = poll_mode_read;
-
- cherokee_thread_deactive_to_polling (HANDLER_THREAD(cgi_base), conn);
return ret_eagain;
case ret_ok:
View
5 cherokee/source.c
@@ -233,11 +233,6 @@ cherokee_source_connect_polling (cherokee_source_t *src,
case ret_eagain:
conn->polling_aim.fd = SOCKET_FD(socket);
conn->polling_aim.mode = poll_mode_write;
-
- ret = cherokee_thread_deactive_to_polling (CONN_THREAD(conn), conn);
- if (ret != ret_ok) {
- return ret_deny;
- }
return ret_eagain;
case ret_error:
return ret_error;
View
5 cherokee/source_interpreter.c
@@ -713,11 +713,6 @@ cherokee_source_interpreter_connect_polling (cherokee_source_interpreter_t *src,
/* wait for the fd */
conn->polling_aim.fd = SOCKET_FD(socket);
conn->polling_aim.mode = poll_mode_write;
-
- ret = cherokee_thread_deactive_to_polling (CONN_THREAD(conn), conn);
- if (ret != ret_ok) {
- return ret_error;
- }
return ret_eagain;
case ret_deny:

0 comments on commit 772f779

Please sign in to comment.
Something went wrong with that request. Please try again.