Fix reverse proxy timeout issues
This commit is contained in:
@ -37,7 +37,7 @@ void fastcgi_frame_handler_func(fastcgi_ctx_t *ctx) {
|
||||
|
||||
int fastcgi_handle_connection(client_ctx_t *ctx, fastcgi_cnx_t **cnx) {
|
||||
sock_set_timeout(&(*cnx)->socket, FASTCGI_TIMEOUT);
|
||||
sock_set_socket_timeout(&(*cnx)->socket, 1);
|
||||
sock_set_socket_timeout(&(*cnx)->socket, FASTCGI_SOCKET_TIMEOUT);
|
||||
|
||||
fastcgi_ctx_t *a = malloc(sizeof(fastcgi_ctx_t));
|
||||
a->closed = 0;
|
||||
|
@ -67,7 +67,7 @@ static int tcp_acceptor(client_ctx_t *ctx) {
|
||||
ctx->host[0] != 0 ? ctx->host : "", ctx->host[0] != 0 ? ") " : "",
|
||||
ctx->cc[0] != 0 ? ctx->cc : "N/A");
|
||||
|
||||
if (sock_set_socket_timeout(client, 1) != 0 || sock_set_timeout(client, CLIENT_TIMEOUT) != 0) {
|
||||
if (sock_set_socket_timeout(client, SOCKET_TIMEOUT) != 0 || sock_set_timeout(client, CLIENT_TIMEOUT) != 0) {
|
||||
error("Unable to set timeout for socket");
|
||||
return -1;
|
||||
}
|
||||
|
Reference in New Issue
Block a user