Skip to content

Commit

Permalink
http: restart timeout handler on receiving chunks
Browse files Browse the repository at this point in the history
  • Loading branch information
fAuernigg committed Feb 10, 2025
1 parent b5a9089 commit de5702c
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/http/client.c
Original file line number Diff line number Diff line change
Expand Up @@ -293,6 +293,10 @@ static int req_recv(struct http_req *req, struct mbuf *mb, bool *last)
return 0;
}

/* restart recv timeout, timeout on no more data received */
tmr_start(&req->conn->tmr, req->cli->conf.recv_timeout,
timeout_handler, req->conn);

while (mbuf_get_left(mb)) {

if (req->rx_len == 0) {
Expand Down

0 comments on commit de5702c

Please sign in to comment.