This check seems to fail even if the VR pref is enabled. I think this is
because we are running this code while very early in process startup.
I think it will not introduce risk because the other process in this case
will be the parent process, so if that's been taken over then we've already
lost.
This also seems to fix the leak that I had to ignore before, probably
because the VR process wasn't even starting up properly before, so I've
removed the leak threshold I had to add.
Differential Revision: https://phabricator.services.mozilla.com/D141170
Automatically generated rewrites of all ParamTraits and IPDLParamTraits
implementations in-tree to use IPC::Message{Reader,Writer}.
Differential Revision: https://phabricator.services.mozilla.com/D140004
Before this change, OtherPid() would only be initialized for one side of an
actor pair when opening an in-process actor using `IToplevelProtocol::Open` or
`IToplevelProtocol::OpenOnSameThread`. This changes the function to directly
accept the other protocol, and initializes the value correctly in all cases.
Differential Revision: https://phabricator.services.mozilla.com/D137168
The changes in this patch stack will change how IPDL generated files are built,
such that these issues are now surfaced, especially during non-unified builds.
Differential Revision: https://phabricator.services.mozilla.com/D137165
Now that we send everything (except sometimes the user value
is sanitized) we should no longer perform this check.
This is also good because it eliminates security code you
have to have (and thus accidently omitting it is a
vulnerability) and changes it to security code that happens
automatically, and is enforced by the compiler (via mandatory
ctor argument.)
Differential Revision: https://phabricator.services.mozilla.com/D138684
This simplifies the number of negations needed,
and makes things easy to understand. I think
anyway; I know that without renaming it I made
several annoying-to-diagnose negation errors...
Differential Revision: https://phabricator.services.mozilla.com/D138682
While we do so, also add a boolean argument to indicate
if we are in a _Content_ process or some other type of
subprocess, which I expect we will need later.
Differential Revision: https://phabricator.services.mozilla.com/D138681
We want to eventually crash if a blocklisted preference
is accessed. In order to do this, we do need to
populate the preference in the pref hashmap of the
subprocess; otherwise when we look up a blocklisted
pref we will just not find anything. We could try to
put the blocklist check at that point; but this won't
work for StaticPrefs; we'd also need to put the blocklist
check there.
Performing a list iteration and string comparison on
every Static Pref call is not acceptable when we can
just populate a bit and check it.
Differential Revision: https://phabricator.services.mozilla.com/D138679
This is a mechanical change which was performed by a script based on the
contents of direct_call.py, and then manually checked over to fix
various rewriting bugs caused by my glorified sed script. See the
previous part for more context on the change.
Differential Revision: https://phabricator.services.mozilla.com/D137227
This simplifies the logic around descriptors significantly, which is
especially useful considering how few places use the type. There is a
small change required on Windows to create the NamedPipe directly and
transfer around each end's handle, rather than connecting between
processes after the fact.
A named pipe has to be used, rather than an anonymous pipe, as
bidirectional communication is required.
Differential Revision: https://phabricator.services.mozilla.com/D130381
`base::KillProcess`, with the `wait` parameter set to true, does a
bounded blocking wait for the process to exit by polling and sleeping in
a loop, with ad-hoc parameters. The only user of that case is the Gecko
Media Plugin code, which doesn't actually need it as discussed in bug
(comments 4-6); also, currently it's blocking the IPC I/O thread in the
parent process, which is not good for browser responsiveness.
Accordingly, this patch deletes that code and removes the parameter.
Differential Revision: https://phabricator.services.mozilla.com/D136662
This simplifies the logic around descriptors significantly, which is
especially useful considering how few places use the type. There is a
small change required on Windows to create the NamedPipe directly and
transfer around each end's handle, rather than connecting between
processes after the fact.
A named pipe has to be used, rather than an anonymous pipe, as
bidirectional communication is required.
Differential Revision: https://phabricator.services.mozilla.com/D130381
This is no longer necessary as the Quantum DOM project is no longer
happening, and removing support simplifies various components inside of
IPDL.
As some code used the support to get a `nsISerialEventTarget` for an
actor's worker thread, that method was replaced with a method which
instead pulls the nsISerialEventTarget from the MessageChannel and
should work on all actors.
Differential Revision: https://phabricator.services.mozilla.com/D135411
This patch splits out AnimationFrameProvider from the Document WebIDL to
allow the workers to implement it. It also splits out a helper class to
manage the requestAnimationFrame callbacks which may be reused on a
worker thread.
Differential Revision: https://phabricator.services.mozilla.com/D130262
This patch splits out AnimationFrameProvider from the Document WebIDL to
allow the workers to implement it. It also splits out a helper class to
manage the requestAnimationFrame callbacks which may be reused on a
worker thread.
Differential Revision: https://phabricator.services.mozilla.com/D130262
gfx/2d/SourceSurfaceD2D1.cpp(201,20): error: variable 'options' set but not used [-Werror,-Wunused-but-set-variable]
D2D1_MAP_OPTIONS options;
^
gfx/thebes/gfxDWriteFontList.h(269,13): error: variable 'hr' set but not used [-Werror,-Wunused-but-set-variable]
HRESULT hr = S_OK;
^
gfx/thebes/gfxGDIFontList.cpp(1020,12): error: variable 'cmapLoaded' set but not used [-Werror,-Wunused-but-set-variable]
bool cmapLoaded = false;
^
gfx/thebes/gfxMacPlatformFontList.mm:1771:10: error: variable 'isStandardFace' set but not used [-Werror,-Wunused-but-set-variable]
bool isStandardFace = false;
^
gfx/thebes/gfxPlatformFontList.cpp(1064,18): error: variable 'rejectedFallbackVisibility' set but not used [-Werror,-Wunused-but-set-variable]
FontVisibility rejectedFallbackVisibility = FontVisibility::Unknown;
^
gfx/vr/service/OculusSession.cpp(1329,12): error: variable 'bNewController' set but not used [-Werror,-Wunused-but-set-variable]
bool bNewController = false;
^
Differential Revision: https://phabricator.services.mozilla.com/D126454
Building with ac_add_options --disable-unified-build on macOS hits the following warnings-as-errors:
gfx/2d/FilterNodeSoftware.cpp:1022:10 [-Wunreachable-code-return] 'return' will never be executed
gfx/2d/DrawTargetCairo.cpp:1957:20 [-Wunused-function] unused function 'GfxMatrixToPixmanTransform'
gfx/thebes/gfxHarfBuzzShaper.cpp:1008:23: warning: unused variable 'sDageshForms' [-Wunused-const-variable]
gfx/thebes/gfxMacPlatformFontList.mm:818:31 [-Wunused-const-variable] unused variable 'kLangFontsDirs'
gfx/tests/gtest/TestSwizzle.cpp:221:21 [-Wunreachable-code] code will never be executed
gfx/tests/gtest/TestTreeTraversal.cpp:16:11 [-Wunused-const-variable] unused variable 'PERFORMANCE_TREE_DEPTH'
gfx/tests/gtest/TestTreeTraversal.cpp:17:11 [-Wunused-const-variable] unused variable 'PERFORMANCE_TREE_CHILD_COUNT'
gfx/tests/gtest/TestTreeTraversal.cpp:18:11 [-Wunused-const-variable] unused variable 'PERFORMANCE_TREE_LEAF_COUNT'
gfx/tests/gtest/TestTreeTraversal.cpp:19:11 [-Wunused-const-variable] unused variable 'PERFORMANCE_REGION_XWRAP'
gfx/vr/VRDisplayPresentation.cpp:151:3 [-Wunreachable-code-loop-increment] loop will run at most once (loop increment never executed)
gfx/ycbcr/scale_yuv_argb.cpp:61:21 [-Wunused-function] unused function 'Abs'
Differential Revision: https://phabricator.services.mozilla.com/D126592
This extends on the changes in part 12a and consumes the new PortRef-based API
in all existing process types other than the fork server. The IPDL C++ unit
tests were already broken before this change, and were not updated.
Differential Revision: https://phabricator.services.mozilla.com/D112777
This extends on the changes in part 12a and consumes the new PortRef-based API
in all existing process types other than the fork server. The IPDL C++ unit
tests were already broken before this change, and were not updated.
Differential Revision: https://phabricator.services.mozilla.com/D112777