We avoid going through Substring which imposes a limit on the string length of
INT32_MAX and failing a MOZ_RELEASE_ASSERT otherwise.
This adds a new `Base64EncodeAppend` function that takes 8-bit char input and
produces 16-bit char output, and appends to an existing string, which is what
we need here to avoid doing a large copy. Base64EncodeHelper is generalized
to accomodate for that.
So in addition to fixing the defect, this also optimizes performance and
memory usage.
Differential Revision: https://phabricator.services.mozilla.com/D87413
The internal Download API and the downloads API for extensions trigger
download requests on behalf of users. These should be considered
first-party requests, and therefore not be restricted by sameSite cookie
restrictions or tracking protection.
This patch has two components:
- Ensure that triggeringPrincipal is always the system principal, to
make sure that `BasePrincipal::IsThirdPartyChannel` returns false
when called by `CookieCommons::IsSameSiteForeign`.
The extension API implementation was the only consumer of the
Download API where triggeringPrincipal wasn't the system principal
(because loadingPrincipal is a moz-extension:-URI since bug 1579911).
- Set `channel.forceAllowThirdPartyCookie` to true, so that cookies are
always included in download requests even if the preference
`network.cookie.cookieBehavior` is 1 (aka BEHAVIOR_REJECT_FOREIGN).
Differential Revision: https://phabricator.services.mozilla.com/D87359
When using the CDM headers in ipc codegen we run into issues where X11 defines
a `Status` macro that tramples the CDM headers. Since we can't undef `Status` in
ipdl we can instead add a header that ipdl can include which does the undef.
Differential Revision: https://phabricator.services.mozilla.com/D87324
Restricting LoadStringCharResult to Latin-1 characters means Warp won't be
able to optimise accesses when Two-Byte characters are present. Instead slow
generic VM calls were used for string accesses.
Differential Revision: https://phabricator.services.mozilla.com/D87101
Implement `MCompare::tryFoldCharCompare` to port the improvements from
bug 813836 and bug 1538690. This wasn't previously handled through `foldsTo`,
because relational comparison support for strings (bug 1538692) wasn't present
at that point of time.
Differential Revision: https://phabricator.services.mozilla.com/D87099
Do this by spinning the event loop until we've done the clone for
preview as appropriate.
This should be much less risky than finishing the previous patches
which would still be nice, but realistically landing them for 81 is not
going to happen.
This just returns without doing nothing in a couple cases, like when
there's already another modal dialog or such. That seems acceptable to
me, it's not clear what better way to do would be.
Differential Revision: https://phabricator.services.mozilla.com/D87484
Wraps the header container and the preferences list in a grid layout
that is meant to be a "single source of truth" for nested grids via
subgrid.
Differential Revision: https://phabricator.services.mozilla.com/D86866
In Bug 1466660, we started deleting the fetches after a task had run, to avoid
interference between tasks. It turns out the only tasks this was for were the
`source-test-jsshell` tasks, which were changed to use an absolute directory in
Bug 1465181. However, since Bug 1568460 we've always used a per-task directory
for fetches, so can remove the work-around of removing fethes.
Differential Revision: https://phabricator.services.mozilla.com/D86670
We define a value `run.workdir` to point to the defaut directory to use for
all sorts of paths, including checkouts, in the job transform. However, that
directory only makes sense for docker-worker tasks, and relative paths should
be used elsewhere. Adjust the paths on non-docker-worker linux tasks to match
macOS paths.
Differential Revision: https://phabricator.services.mozilla.com/D86668
Even though it hasn't normalize white-spaces before invisible `<br>` element,
it needs to do it for making them visible. Therefore, we should make it
use the new method in this case too.
Depends on D87030
Differential Revision: https://phabricator.services.mozilla.com/D87031