move to stock esp_http_server but keep it under control

- means 3 sockets are used (data + 2 for control)
- but LRU is activated (uses the 2 extra sockets to wake from select)
- backlog is just 1 (listen)
- only 3 sockets can be consumed before LRU activates
- for now, connections are kept-alive
This commit is contained in:
Philippe G
2021-12-14 11:52:51 -08:00
parent 412880d628
commit a266c07114
12 changed files with 117 additions and 460 deletions

View File

@@ -353,6 +353,8 @@ static esp_err_t set_content_type_from_req(httpd_req_t *req)
return ESP_FAIL;
}
set_content_type_from_file(req, filename);
// we might have to disallow keep-alive in the future
// httpd_resp_set_hdr(req, "Connection", "close");
return ESP_OK;
}