Fix proxying header assertion failure.
Re-write Server of proxied requests to avoid: coolwsd: ./net/HttpRequest.hpp:945: bool http::Response::writeData(Buffer &) const: Assertion `get("Server") == http::getServerString() && "Server Agent is always set in http::Response ctor"' failed. Change-Id: I6076dbc355b0f42a6367271893c9732195c8eb2a Signed-off-by: Michael Meeks <michael.meeks@collabora.com>
This commit is contained in:
parent
17ae1f2ffe
commit
f05cea2b13
1 changed files with 3 additions and 0 deletions
|
@ -65,6 +65,9 @@ void ProxyRequestHandler::handleRequest(const std::string& relPath,
|
|||
|
||||
CacheFileHash[httpSession->getUrl()] = httpResponse;
|
||||
|
||||
// We're proxying, we take responsibility.
|
||||
httpResponse->set("Server", http::getServerString());
|
||||
|
||||
socket->sendAndShutdown(*httpResponse);
|
||||
}
|
||||
else
|
||||
|
|
Loading…
Reference in a new issue