From 0530317f89a06c8ea8ae1a57b5e838581a232f4b Mon Sep 17 00:00:00 2001 From: lxsang Date: Mon, 15 Oct 2018 21:35:57 +0200 Subject: [PATCH] unkown bug --- http_server.c | 12 ++---------- libs/handle.c | 4 ++-- 2 files changed, 4 insertions(+), 12 deletions(-) diff --git a/http_server.c b/http_server.c index 52f1a33..b767d4c 100644 --- a/http_server.c +++ b/http_server.c @@ -223,22 +223,14 @@ void *accept_request(void *data) task->handle = accept_request; return task; } - /*else + else { if (!FD_ISSET(client->sock, &read_flags)) { - if(client->attempt > MAX_ATTEMPT) - { - LOG("Too much attempt for read, give up on %d\n", client->sock); - server_config.connection++; - unknow(rq->client); - return task; - } - client->attempt++; task->handle = accept_request; return task; } - }*/ + } #endif client->attempt = 0; server_config.connection++; diff --git a/libs/handle.c b/libs/handle.c index 8ec4ef5..6ff7603 100644 --- a/libs/handle.c +++ b/libs/handle.c @@ -163,7 +163,7 @@ int antd_send(void *src, const void* data, int len) break; } } - source->attempt = 0; + //source->attempt = 0; } else { @@ -271,7 +271,7 @@ int antd_recv(void *src, void* data, int len) break; } } - source->attempt = 0; + //source->attempt = 0; /* int stat, r, st; do{