Now we create barriers for all shutdown phases (xpcom-will-shutdown included)
and have them register the previous phase's completion as a blocker. This
allows for a simplified implementation of IOUtilsShutdownBlocker, especially in
the next patch where we add support for an additional shutdown phase.
In normal shutdown, the previous phase will already be completed by the time we
hit the blocker. However, in xpcshell tests, we are not going to hit the
profile-before-change etc. shutdown phases, so we still need to ensure that IO
finished, so we can recursively wait on previous phases to complete.
Differential Revision: https://phabricator.services.mozilla.com/D152922
Now we create barriers for all shutdown phases (xpcom-will-shutdown included)
and have them register the previous phase's completion as a blocker. This
allows for a simplified implementation of IOUtilsShutdownBlocker, especially in
the next patch where we add support for an additional shutdown phase.
In normal shutdown, the previous phase will already be completed by the time we
hit the blocker. However, in xpcshell tests, we are not going to hit the
profile-before-change etc. shutdown phases, so we still need to ensure that IO
finished, so we can recursively wait on previous phases to complete.
Differential Revision: https://phabricator.services.mozilla.com/D152922
Currently, Subprocess.jsm on Unix uses js-ctypes to call `posix_spawn`.
This has some issues, primarily that file descriptors are inherited by
the child process unless explicitly opted-out, which unfortunately a lot
of code doesn't do. This patch changes it to use IPC process launching,
where fd inheritance is opt-in, by:
1. Extending `base::LaunchApp` to handle a few features that Subprocess
needs (setting the process's working directory, specifying the full
environment, and the macOS `disclaim` flag)
2. Adding a WebIDL method to `IOUtils` to expose that function to JS
(currently Unix-only; Windows could also be supported but it would
probably want to use a different IDL type for strings, given that the
OS APIs use 16-bit code units).
3. Replacing the part of Subprocess that invokes `posix_spawn` (and
related functions) by calling that method; the rest of Subprocess's
machinery to manage pipes and I/O is unchanged. (The Windows backend
is also unchanged; I'm not aware of any functional issues there.)
This results in some dead code, which is removed.
Differential Revision: https://phabricator.services.mozilla.com/D152336
Now we create barriers for all shutdown phases (xpcom-will-shutdown included)
and have them register the previous phase's completion as a blocker. This
allows for a simplified implementation of IOUtilsShutdownBlocker, especially in
the next patch where we add support for an additional shutdown phase.
In normal shutdown, the previous phase will already be completed by the time we
hit the blocker. However, in xpcshell tests, we are not going to hit the
profile-before-change etc. shutdown phases, so we still need to ensure that IO
finished, so we can recursively wait on previous phases to complete.
Differential Revision: https://phabricator.services.mozilla.com/D152922
Instead of trying to get the ScriptObjectPrincipal
of a window; use the window's Document, which will
take into account a lot more context.
Differential Revision: https://phabricator.services.mozilla.com/D150584
This bug unsets the location listeners when the Android lifecycle
`onPause` is called and sets the location listeners when `onResume` is
called (if location was in use).
Differential Revision: https://phabricator.services.mozilla.com/D149442
Even tho it is a configuration error, it is extremely confusing to click
"Allow" in Firefox and get a "denied access" error.
Instead fall back to MLS once we error, like other location providers
do.
MANUAL PUSH: Maciej doesn't have editbugs to approve patches yet, see
bug 1772813.
Differential Revision: https://phabricator.services.mozilla.com/D147864