Fix header handling versus internal handling of content-type and content-length (Fix #86)

This commit is contained in:
Mathieu Carbou
2024-09-02 22:39:49 +02:00
parent 4f25782aa3
commit f9cfba3351
6 changed files with 75 additions and 38 deletions

View File

@@ -1192,7 +1192,8 @@ void AsyncWebSocketResponse::_respond(AsyncWebServerRequest* request) {
request->client()->close(true);
return;
}
String out(_assembleHead(request->version()));
String out;
_assembleHead(out, request->version());
request->client()->write(out.c_str(), _headLength);
_state = RESPONSE_WAIT_ACK;
}