Skip to content

Commit 779a993

Browse files
authored
Merge pull request #98 from doyoubi/hotfix/DeadLoop
Fix dead loop
2 parents 9367d4b + 75fc258 commit 779a993

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

src/timer.c

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,11 @@ void check_connections(struct context *ctx)
5050
// the client connection is turned into an intermediate state.
5151
// In this state the connection object has not called conn_free so the c->fd is not -1 here.
5252
// But it should not call client_eof again.
53-
if (c->eof) continue;
53+
if (c->eof) {
54+
LOG(WARN, "zombie client");
55+
c = n;
56+
continue;
57+
}
5458

5559
if (c->info->last_active > 0
5660
&& now - c->info->last_active > config.client_timeout)

0 commit comments

Comments
 (0)