Closed Bug 1650837 Opened 5 years ago Closed 5 years ago

JSProcessActor filtering doesn't work correctly

Categories

(Core :: DOM: Content Processes, defect, P2)

defect

Tracking

()

RESOLVED FIXED
mozilla80
Fission Milestone M6a
Tracking Status
firefox80 --- fixed

People

(Reporter: nika, Assigned: nika)

References

Details

Attachments

(8 files)

The current JSProcessActor test suite doesn't actually test the remoteTypes filtering, and after adding tests, the filtering doesn't work correctly. This patch is to track fixing these issues.

Previously this option wasn't correctly copied from the WebIDL configuration
object, meaning that it was always ignored.

This is similar to JSWindowActor's includeChrome option, and defaults to
'false'. If users want to also instantiate the actor in-process, they can set
this option to 'true'.

This is needed specifically for tests, which need to be able to unregister &
re-register the same actor with different configuration options. With
JSWindowActors, we can create new windows after each actor is unregistered, but
we can't do this with in-process JSProcessActors.

This is no longer necessary, as we now tear down the previously registered
window actors when they're unregistered.

The pref is automatically disabled when disabling unsigned extensions, which can
cause issues. This hacks around that issue in the one place which I noticed
doing that.

This improves the usability of the exceptions produced in this situation.

The reply was never used, and due to other changes in this bug, was causing
ignored exceptions to be thrown occasionally when a query was sent immediately
before unregistering the actor.

Pushed by nlayzell@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/3d4556d1449c Part 1: Fix broken JSProcessActor remoteType filtering, r=kmag https://hg.mozilla.org/integration/autoland/rev/968555d641c6 Part 2: Add an includeParent JSProcessActor config option, r=kmag https://hg.mozilla.org/integration/autoland/rev/a14f2e220852 Part 3: Destroy active actors when they are unregistered, r=kmag https://hg.mozilla.org/integration/autoland/rev/e28575cd2ec2 Part 4: Add tests for JSProcessActor filtering, r=kmag https://hg.mozilla.org/integration/autoland/rev/6b119cf71282 Part 5: Avoid creating new windows for every JSActor test, r=kmag https://hg.mozilla.org/integration/autoland/rev/cbc811712a24 Part 6: Hack around SpecialPowers being disabled, r=kmag https://hg.mozilla.org/integration/autoland/rev/f568bf729072 Part 7: Include message name in error when pending queries are rejected, r=kmag https://hg.mozilla.org/integration/autoland/rev/b878ef9bc226 Part 8: Avoid unnecessary sendQuery for DevToolsFrameParent:packet, r=jdescottes
Regressions: 1654730
No longer regressions: 1654730
See Also: → 1654730
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: