Consistently pass around IPC::Message behind a UniquePtr
Categories
(Core :: IPC, task)
Tracking
()
Tracking | Status | |
---|---|---|
firefox102 | --- | fixed |
People
(Reporter: nika, Assigned: nika)
References
Details
Attachments
(3 files)
IPC::Message currently is passed differently in many places, either being directly moved or stored behind a UniquePtr
(or raw pointer). This inconsistency requires things such as IPC::Message
having a manually-implemented move constructor and assignment operator (https://searchfox.org/mozilla-central/rev/c7183440fe8ad391e2ab2e990229dd85fac318d3/ipc/chromium/src/chrome/common/ipc_message.cc#56-71,87-99), and generally makes some code trickier to follow.
This bug tracks a patch to remove these move constructors, and instead always pass IPC::Message
around behind a UniquePtr
to simplify things and make adding e.g. members to IPC::Message
less error prone.
Assignee | ||
Comment 1•2 years ago
|
||
This makes passing around the type more consistent, and hopefully will make
changes to IPC::Message easier to work with in the future.
In addition, this should save us a few copies as we move the message type into
and out of UniquePtr, however I expect this won't make much of a difference.
Assignee | ||
Comment 2•2 years ago
|
||
All accesses except those through the xpcom interfaces were already
guarded, and given it can be mutated, this seemed easier than adding
thread assertions or similar.
Depends on D145885
Comment 4•2 years ago
•
|
||
Backed out 2 changesets (Bug 1768476) for causing build bustages in ProtocolFuzzer.h
Log: https://treeherder.mozilla.org/logviewer?job_id=377604506&repo=autoland&lineNumber=10096
https://treeherder.mozilla.org/logviewer?job_id=377603878&repo=autoland&lineNumber=101781
Backout: https://hg.mozilla.org/integration/autoland/rev/5b2d681db7a638f1c882a80b05d3710443def80d
Assignee | ||
Updated•2 years ago
|
Assignee | ||
Comment 7•2 years ago
|
||
https://hg.mozilla.org/mozilla-central/rev/5933da5f8e3d
https://hg.mozilla.org/mozilla-central/rev/5a1aef360088
https://hg.mozilla.org/mozilla-central/rev/41c3bedf3d95
https://hg.mozilla.org/mozilla-central/rev/20902b19a0ef
Description
•