summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMoonchild <moonchild@palemoon.org>2023-10-25 04:29:37 +0200
committerMoonchild <moonchild@palemoon.org>2023-10-25 04:29:37 +0200
commit688ed9a1140c944c6b5a50bf75025b066bd002d7 (patch)
tree76392e2adda6b6b70e4a6ae2d5a262940e00f7a0
parentc30be25773684b7182d41a94f880f7f29b947569 (diff)
downloaduxp-688ed9a1140c944c6b5a50bf75025b066bd002d7.tar.gz
[DOM] Ignore status 206 and vary header checking for opaque responses in
the Cache API.
-rw-r--r--dom/cache/TypeUtils.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/dom/cache/TypeUtils.cpp b/dom/cache/TypeUtils.cpp
index 1af5ee9458..89fe2a62fb 100644
--- a/dom/cache/TypeUtils.cpp
+++ b/dom/cache/TypeUtils.cpp
@@ -190,7 +190,7 @@ TypeUtils::ToCacheResponseWithoutBody(CacheResponse& aOut,
aOut.statusText() = aIn.GetUnfilteredStatusText();
RefPtr<InternalHeaders> headers = aIn.UnfilteredHeaders();
MOZ_DIAGNOSTIC_ASSERT(headers);
- if (HasVaryStar(headers)) {
+ if (aIn.Type() != ResponseType::Opaque && HasVaryStar(headers)) {
aRv.ThrowTypeError<MSG_RESPONSE_HAS_VARY_STAR>();
return;
}