summaryrefslogtreecommitdiff
path: root/Libraries
diff options
context:
space:
mode:
authorLuke <luke.wilde@live.co.uk>2020-11-11 07:46:25 +0000
committerAndreas Kling <kling@serenityos.org>2020-11-11 12:15:18 +0100
commit62a74bf282ec8f179f148428190a6e0bac425446 (patch)
treecaf771a275ea2ad2ae1e1f5e9a44e659e34c9b63 /Libraries
parent397049aae8a0c6f849e6f03a4033e1a7990e80ce (diff)
downloadserenity-62a74bf282ec8f179f148428190a6e0bac425446.zip
LibWeb: Advertise to servers that we support gzip encoding
We've had gzip support for a while now, but it never really got used because we never advertised it.
Diffstat (limited to 'Libraries')
-rw-r--r--Libraries/LibWeb/Loader/ResourceLoader.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/Libraries/LibWeb/Loader/ResourceLoader.cpp b/Libraries/LibWeb/Loader/ResourceLoader.cpp
index 1911c7c39e..897c684ecb 100644
--- a/Libraries/LibWeb/Loader/ResourceLoader.cpp
+++ b/Libraries/LibWeb/Loader/ResourceLoader.cpp
@@ -158,6 +158,7 @@ void ResourceLoader::load(const LoadRequest& request, Function<void(const ByteBu
if (url.protocol() == "http" || url.protocol() == "https" || url.protocol() == "gemini") {
HashMap<String, String> headers;
headers.set("User-Agent", m_user_agent);
+ headers.set("Accept-Encoding", "gzip");
for (auto& it : request.headers()) {
headers.set(it.key, it.value);