1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-26 05:37:35 +00:00

LibHTTP: Use 'close' as the default value for Connection in HTTP/1.0

Unlike HTTP/1.1 and above, the default behaviour for HTTP/1.0 servers
is to close the connection after sending the response.
This commit is contained in:
Idan Horowitz 2022-10-01 18:11:36 +03:00 committed by Andreas Kling
parent 66bde66f49
commit 7578039188
2 changed files with 14 additions and 2 deletions

View file

@ -52,6 +52,7 @@ protected:
HttpRequest m_request;
State m_state { State::InStatus };
Core::Stream::BufferedSocketBase* m_socket { nullptr };
bool m_legacy_connection { false };
int m_code { -1 };
HashMap<String, String, CaseInsensitiveStringTraits> m_headers;
Vector<String> m_set_cookie_headers;