If any of the file operations fail, we need to ensure we still dispatch to the main thread.
If the dispatch fails, leak the runnable (and the things it owns) rather than crash when we try to release them off main thread.
Talos causes accessibility to be instantiated only in the content
process. That means PDocAccessibleConstructor messages can be recieved
by the parent when GetAccService() returns null. The easiest way of
dealing with this is moving DocManager::mRemoteDocuments from a member
of the acc service singleton to its own global. That means the parent
process can track accessible documents in child processes without
instantiating a11y in the parent process.
This changes the interface so that the code which determines the flags
can live in one place, but checking the flags doesn't need to call into
another library.
Also removes the no-op wrappers for Set*Sandbox when disabled at build
time; nothing used them, one of them was unusable due to having the wrong
type, and all they really accomplish is allowing sloppiness with ifdefs
(which could hide actual mistakes).
We now allow profiling the content process for e10s, and plugin processes.
--HG--
extra : rebase_source : 1f2e35d4d55b33b56160132893dbf7d4787925fa
extra : amend_source : d03465d4318f8e50c7624ad0eeb681b30c068b11
Modern OSs adjust process scheduling based on CPU-boundedness and Interface-boundedness. A process performing a lot of UI tasks requires lower-latency than a CPU-bound process. For this reason, at least on Windows (but probably also Linux and Mac), in e10s, resize events are sent at a much higher rate than non-e10s, where the main process has to do the work to respond to them. This was supposed to be handled by the 'compress' option in IPDL but its duplicate-event test was very imprecise - it only tested the *oldest* message in the queue. This patch searches the messagequeue/deque to remove *any* duplicate. deque::erase is linear but this is a very uncommon case - currently only two compressed IPDL messages exist in the entire code base. Also, these queues are small.
This adds "hasSeccompBPF" for seccomp-bpf support; other "has" keys
will be added in the future (e.g., user namespaces).
This also adds "canSandboxContent" and "canSandboxMedia", which are
absent if the corresponding type of sandboxing isn't enabled at build
type (or is disabled with environment variables), and otherwise present
as a boolean indicating whether that type of sandboxing is supported.
Currently this is always the same as hasSeccompBPF, but that could change
in the future.
Some changes have been made to the "mozilla/Sandbox.h" interface to
support this; the idea is that the MOZ_DISABLE_*_SANDBOX environment
variables should be equivalent to disabling MOZ_*_SANDBOX at build time.