This makes sure we parse the merged/stored version of `cache-control`
instead of just the latest-received header.
`ResponseHead::ParseHeaderLine_locked` parses each header as it comes in.
It then updates its member variables based on that header.
For `cache-control`, it's important to reparse the merged (updated)
version of the header instead of the most recent one, otherwise we'll miss
directives present in previously received headers.
Resolves#2852
Only mention OpenGL accelerated canvas flag when it's relevant, and rename
the entry to be more descriptive, to prevent confusion for users looking
at Troubleshooting Information.
This now matches the logic in our equivalent Windows code, and this is
also per spec ("number of bits...excluding the alpha channel"):
https://drafts.csswg.org/cssom-view/#dom-screen-colordepth
With this change, the WPT test starts passing on Ubuntu 22.04
(which was previously flagged as an unexpected failure).
This moves the checking code back to NS_SniffContent and specifically
checks requests for either:
- Empty `Content-type` header, OR
- A known JSON MIME type
If present, sniffing is allowed despite `nosniff` because in the first
case this is webmaster error (conflicting `nosniff` without MIME type
would always fail, so sniff it), and in the second case we need this
carveout or our json viewer will break.
This fixes a regression for the JSON viewer from part 1 as it relies on
sniffing to prettify (and should carve out the exception even if `nosniff`
headers are sent).
No real functional changes otherwise. Just catering to a corner case.
This gets rid of all the unnecessary named functions to be replaced with
a straightforward check `IsWindows10BuildOrLater(WinBuild::{build})`
Where `WinBuild` is an enum with common `{build}` names of Win 10+
versions: `Win10v1809`, `Win10v21H2`, `Win11RTM`, `Win11v24H2`, etc.
None of these named functions were actually in use, so no other changes
should be necessary in the platform.
Flip the pref. We want this on by default for web compat.
Users can disable it if they really want to, but it doesn't expose
anything of note to web content anyway that can't already be determined.
This DOM/Web API is entirely irrelevant for desktop use.
We give back the width/height of the root scrollframe of content and
for scale we pass forward our dpp resolution (usually 1.0).
Since we have no "no touch" zones in our content on desktop,. the rest
(origin and offset) is hard-coded to (0,0).
Trying to do a positive check on nested URIs apparently doesn't work,
but the handling could be simplified to just check for non-null mURI
instead - this also fixes plugin loading (which broke with the previous
check).
If a website would nor supply a URI for object loading code, the browser
would crash on a null deref.
This reintroduces the nestedURI check to make sure we have a valid URI.