summaryrefslogtreecommitdiff
path: root/Services/ProtocolServer/ClientConnection.cpp
diff options
context:
space:
mode:
authorAndreas Kling <kling@serenityos.org>2020-05-21 12:27:42 +0200
committerAndreas Kling <kling@serenityos.org>2020-05-21 12:27:42 +0200
commit897998017af64a641ddbd82e5d12d08f6bcc2aea (patch)
tree9dd276bcea06850b4d693083abdaf1184ccbb7db /Services/ProtocolServer/ClientConnection.cpp
parent25cfdf3f6790ce9b7650e2a54adf1552826c7a0d (diff)
downloadserenity-897998017af64a641ddbd82e5d12d08f6bcc2aea.zip
ProtocolServer: Support request headers
You can now pass a dictionary of request headers when starting a new download in ProtocolServer. The HTTP and HTTPS protocol will include the headers in their requests.
Diffstat (limited to 'Services/ProtocolServer/ClientConnection.cpp')
-rw-r--r--Services/ProtocolServer/ClientConnection.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/Services/ProtocolServer/ClientConnection.cpp b/Services/ProtocolServer/ClientConnection.cpp
index 40387f4208..f688dc58a8 100644
--- a/Services/ProtocolServer/ClientConnection.cpp
+++ b/Services/ProtocolServer/ClientConnection.cpp
@@ -64,7 +64,7 @@ OwnPtr<Messages::ProtocolServer::StartDownloadResponse> ClientConnection::handle
auto* protocol = Protocol::find_by_name(url.protocol());
if (!protocol)
return make<Messages::ProtocolServer::StartDownloadResponse>(-1);
- auto download = protocol->start_download(*this, url);
+ auto download = protocol->start_download(*this, url, message.request_headers().entries());
if (!download)
return make<Messages::ProtocolServer::StartDownloadResponse>(-1);
auto id = download->id();