Commit Graph

336 Commits

Author SHA1 Message Date
Emilio Cobos Álvarez
71bf77b3fe Bug 1904442 - Rename GlobalTeardownObserver::GetOwner to GetOwnerWindow. r=smaug,media-playback-reviewers,dom-storage-reviewers,aosmond,padenot,asuth
Also HasOrHasHadOwner to HasOrHasHadOwnerWindow.

Differential Revision: https://phabricator.services.mozilla.com/D214772
2024-07-01 11:49:59 +00:00
Jan Varga
fd37799016 Bug 1799374 - Add support for tracking request ids to cursor continue operation; r=dom-storage-reviewers,asuth
Differential Revision: https://phabricator.services.mozilla.com/D204195
2024-03-23 08:42:40 +00:00
Jan Varga
8047aa1ecd Bug 1799374 - Add support for tracking request ids to cursor opening operation; r=dom-storage-reviewers,asuth
Differential Revision: https://phabricator.services.mozilla.com/D204193
2024-03-23 08:42:40 +00:00
Jan Varga
be2e9f5ac4 Bug 1799374 - Add support for tracking request ids to normal transaction operations; r=dom-storage-reviewers,asuth
Differential Revision: https://phabricator.services.mozilla.com/D204192
2024-03-23 08:42:40 +00:00
Andrew Sutherland
7db13a440a Bug 1879259 - Use GlobalTeardownObserver for consistency on workers. r=dom-storage-reviewers,janv
This removes the manual global tracking which was only correctly hooked
up for windows, but missed other global types, especially workers.
Because GlobalTeardownObserver is reliably notified of when to
disconnect, it is able to "safely" hold a raw non-owning pointer which
simplifies cycle collection somewhat.  (That design decision was
originally part of DOMEventTargetHelper which GlobalTeardownObserver
was extracted from.)  It also provides a pre-cached window getter.

This test includes a WPT test that reliably fails without the fix and
passes with the fix.

Differential Revision: https://phabricator.services.mozilla.com/D201188
2024-02-16 17:06:48 +00:00
Nika Layzell
7db34c95ff Bug 1874739 - Part 4: Make PBackgroundIDBDatabase refcounted, r=dom-storage-reviewers,janv
This is part of removing [ManualDealloc] from all protocols which manage other
protocols.

Differential Revision: https://phabricator.services.mozilla.com/D198614
2024-01-19 20:23:19 +00:00
Jan Varga
7d0caa7f80 Bug 1857979 - Ignore responses which need to deserialize structured clone data when the global is already gone; r=dom-storage-reviewers,jstutte
Differential Revision: https://phabricator.services.mozilla.com/D191271
2023-10-18 16:04:47 +00:00
Sylvestre Ledru
b0fe72dee5 Bug 1856795 - Remove redundant member init r=emilio
Done with:
./mach static-analysis check --checks="-*, readability-redundant-member-init" --fix .

https://clang.llvm.org/extra/clang-tidy/checks/readability/redundant-member-init.html

Differential Revision: https://phabricator.services.mozilla.com/D190002
2023-10-15 15:29:02 +00:00
Cristina Horotan
7388749830 Backed out 2 changesets (bug 1856795) for causing build bustage at BasicEvents.h CLOSED TREE
Backed out changeset 1d98b028923a (bug 1856795)
Backed out changeset eae2ac93e17c (bug 1856795)
2023-10-14 21:42:14 +03:00
Sylvestre Ledru
4a97019e39 Bug 1856795 - Remove redundant member init r=emilio
Done with:
./mach static-analysis check --checks="-*, readability-redundant-member-init" --fix .

https://clang.llvm.org/extra/clang-tidy/checks/readability/redundant-member-init.html

Differential Revision: https://phabricator.services.mozilla.com/D190002
2023-10-14 17:34:26 +00:00
Nika Layzell
f685760140 Bug 1607634 - Part 4b: Changes for not-nullable actor types being wrapped in NotNull, r=ipc-reviewers,necko-reviewers,mccr8
These are the code changes required by the IPDL changes in part 4a.

Differential Revision: https://phabricator.services.mozilla.com/D168887
2023-03-20 15:40:36 +00:00
Nika Layzell
ce0f2fd9a8 Bug 1814683 - Part 1: Combine parent/child fields in IPDL structs/unions, r=ipc-reviewers,necko-reviewers,mccr8
This combines the multiple fields or variants which were previously used to
track sided types like protocol types into a single field wrapped with a
SideVariant.

This will be used in the next part to avoid the need for default constructors
for actor types allowing the proper types to be used.

Differential Revision: https://phabricator.services.mozilla.com/D168879
2023-03-20 15:40:31 +00:00
Iulian Moraru
0c8d23ecea Backed out 14 changesets (bug 1607634, bug 1814683, bug 1815177, bug 1814686) for causing build bustages on MaybeStorageBase. CLOSED TREE
Backed out changeset ae1c0551cea5 (bug 1815177)
Backed out changeset a11cafaa1884 (bug 1814686)
Backed out changeset 621507521762 (bug 1814686)
Backed out changeset ad692c73e381 (bug 1814686)
Backed out changeset 3be031e503dc (bug 1607634)
Backed out changeset aebbaa145d2d (bug 1607634)
Backed out changeset 9aa1f346fe14 (bug 1607634)
Backed out changeset e3eb77ad55ca (bug 1607634)
Backed out changeset e60591e5d5cf (bug 1607634)
Backed out changeset 6e43042d204a (bug 1814683)
Backed out changeset 1706e88652d6 (bug 1814683)
Backed out changeset 6878a1590e91 (bug 1814683)
Backed out changeset b1c980c834d8 (bug 1814683)
Backed out changeset 94480b82d102 (bug 1814683)
2023-03-15 01:58:36 +02:00
Nika Layzell
43fc8fd043 Bug 1607634 - Part 4b: Changes for not-nullable actor types being wrapped in NotNull, r=ipc-reviewers,necko-reviewers,mccr8
These are the code changes required by the IPDL changes in part 4a.

Differential Revision: https://phabricator.services.mozilla.com/D168887
2023-03-14 19:31:40 +00:00
Nika Layzell
a0d0b2fb86 Bug 1814683 - Part 1: Combine parent/child fields in IPDL structs/unions, r=ipc-reviewers,necko-reviewers,mccr8
This combines the multiple fields or variants which were previously used to
track sided types like protocol types into a single field wrapped with a
SideVariant.

This will be used in the next part to avoid the need for default constructors
for actor types allowing the proper types to be used.

Differential Revision: https://phabricator.services.mozilla.com/D168879
2023-03-14 19:31:36 +00:00
Kagami Sascha Rosylight
92d5815f14 Bug 1500343 - Part 10: Remove IDBFileHandle/IDBFileRequest/IDBMutableFile r=dom-storage-reviewers,asuth
Differential Revision: https://phabricator.services.mozilla.com/D160385
2023-02-23 08:59:09 +00:00
Kagami Sascha Rosylight
e83ba6f383 Bug 1500343 - Part 8: Remove PBackgroundMutableFile r=dom-storage-reviewers,asuth
Differential Revision: https://phabricator.services.mozilla.com/D160383
2023-02-23 08:59:09 +00:00
Kagami Sascha Rosylight
75514f79b2 Bug 1500343 - Part 7: Remove PBackgroundFileHandle r=dom-storage-reviewers,asuth
Differential Revision: https://phabricator.services.mozilla.com/D159891
2023-02-23 08:59:08 +00:00
Kagami Sascha Rosylight
bb5b5c4af3 Bug 1500343 - Part 6: Remove PBackgroundFileRequest r=dom-storage-reviewers,asuth
Differential Revision: https://phabricator.services.mozilla.com/D159856
2023-02-23 08:59:08 +00:00
Kagami Sascha Rosylight
d39748443e Bug 1500343 - Part 5: Remove PBackgroundIDBDatabaseRequest r=dom-storage-reviewers,asuth
The only use was in IDBDatabase::CreateMutableFile which is removed in part 1.

Differential Revision: https://phabricator.services.mozilla.com/D159734
2023-02-23 08:59:07 +00:00
Iulian Moraru
04ad484c0c Backed out 7 changesets (bug 1500343) for causing build bustages on ActorsParent.cpp. CLOSED TREE
Backed out changeset 5d0b35ae2241 (bug 1500343)
Backed out changeset abe4c30b975e (bug 1500343)
Backed out changeset c5c7e5d59035 (bug 1500343)
Backed out changeset de71281af75c (bug 1500343)
Backed out changeset 220abddba749 (bug 1500343)
Backed out changeset f6a065149ce1 (bug 1500343)
Backed out changeset 1f9e20fcae19 (bug 1500343)
2023-02-23 01:51:44 +02:00
Kagami Sascha Rosylight
729748ab06 Bug 1500343 - Part 10: Remove IDBFileHandle/IDBFileRequest/IDBMutableFile r=dom-storage-reviewers,asuth
Differential Revision: https://phabricator.services.mozilla.com/D160385
2023-02-22 20:03:18 +00:00
Kagami Sascha Rosylight
0f01aa9510 Bug 1500343 - Part 8: Remove PBackgroundMutableFile r=dom-storage-reviewers,asuth
Differential Revision: https://phabricator.services.mozilla.com/D160383
2023-02-22 20:03:17 +00:00
Kagami Sascha Rosylight
83ff9591a5 Bug 1500343 - Part 7: Remove PBackgroundFileHandle r=dom-storage-reviewers,asuth
Differential Revision: https://phabricator.services.mozilla.com/D159891
2023-02-22 20:03:16 +00:00
Kagami Sascha Rosylight
e5a962e680 Bug 1500343 - Part 6: Remove PBackgroundFileRequest r=dom-storage-reviewers,asuth
Differential Revision: https://phabricator.services.mozilla.com/D159856
2023-02-22 20:03:16 +00:00
Kagami Sascha Rosylight
2b712c03e4 Bug 1500343 - Part 5: Remove PBackgroundIDBDatabaseRequest r=dom-storage-reviewers,asuth
The only use was in IDBDatabase::CreateMutableFile which is removed in part 1.

Differential Revision: https://phabricator.services.mozilla.com/D159734
2023-02-22 20:03:15 +00:00
Kagami Sascha Rosylight
1b0ef06291 Bug 1354500 - Part 3: Remove indexedDB/PermissionRequestBase r=dom-storage-reviewers,asuth
Differential Revision: https://phabricator.services.mozilla.com/D151418
2022-07-15 01:55:27 +00:00
Nika Layzell
1f4efe0c11 Bug 1754004 - Part 3: Move RemoteLazyInputStream to its own toplevel protocol, r=asuth,necko-reviewers,dragana
This is a complete rewrite of RemoteLazyInputStream to run off of its own
toplevel protocol, rather than being managed by other protocols like
PBackground or PContent. This should improve performance thanks to no longer
needing to operate on a main or worker thread, and due to no longer needing the
migration step for the stream actor.

This also acts as a step towards no longer requiring a manager actor to
serialize input streams, as the type is now actor-agnostic, and should support
being sent over IPC between any pair of processes.

Differential Revision: https://phabricator.services.mozilla.com/D141040
2022-05-13 14:16:10 +00:00
Noemi Erli
d4d5b7703c Backed out 22 changesets (bug 1696894, bug 1759569, bug 1754031, bug 1759563, bug 1759572, bug 1754004) for causing leack failures CLOSED TREE
Backed out changeset 673ecd5337e1 (bug 1754004)
Backed out changeset ecbf5f3c51de (bug 1754004)
Backed out changeset fc6c39f56d21 (bug 1754004)
Backed out changeset 5b3d58fbaf9d (bug 1696894)
Backed out changeset 2e56c89cf55d (bug 1754004)
Backed out changeset b7723490f025 (bug 1754004)
Backed out changeset 1dfbf61ff5dd (bug 1754004)
Backed out changeset e73abb071bb3 (bug 1754004)
Backed out changeset f9abe4fbf501 (bug 1754004)
Backed out changeset ee7aeb631cd9 (bug 1754004)
Backed out changeset d66aacfcf983 (bug 1754004)
Backed out changeset 5c2872ad6912 (bug 1754004)
Backed out changeset e1ae48f30d2c (bug 1754004)
Backed out changeset 849b63707d7f (bug 1754004)
Backed out changeset 36563e3b1e04 (bug 1754004)
Backed out changeset ccb4be659107 (bug 1754004)
Backed out changeset 659581d4159b (bug 1754004)
Backed out changeset 611ea76d7a9c (bug 1754004)
Backed out changeset 9b24b561698c (bug 1759572)
Backed out changeset f820e0f209ff (bug 1759563)
Backed out changeset 8d82066fa181 (bug 1759569)
Backed out changeset a2835afab1ad (bug 1754031)
2022-05-11 06:16:25 +03:00
Nika Layzell
7749679cc8 Bug 1754004 - Part 3: Move RemoteLazyInputStream to its own toplevel protocol, r=asuth,necko-reviewers,dragana
This is a complete rewrite of RemoteLazyInputStream to run off of its own
toplevel protocol, rather than being managed by other protocols like
PBackground or PContent. This should improve performance thanks to no longer
needing to operate on a main or worker thread, and due to no longer needing the
migration step for the stream actor.

This also acts as a step towards no longer requiring a manager actor to
serialize input streams, as the type is now actor-agnostic, and should support
being sent over IPC between any pair of processes.

Differential Revision: https://phabricator.services.mozilla.com/D141040
2022-05-10 22:27:42 +00:00
Noemi Erli
f80f2dfca4 Backed out 22 changesets (bug 1759572, bug 1759563, bug 1754004, bug 1754031, bug 1759569, bug 1696894) for causing multiple failures CLOSED TREE
Backed out changeset d69647a725a1 (bug 1754004)
Backed out changeset 09fc506865d7 (bug 1754004)
Backed out changeset 648e3dd4b62f (bug 1754004)
Backed out changeset 3465158ee230 (bug 1696894)
Backed out changeset b08475bbfbd9 (bug 1754004)
Backed out changeset dfabce587a56 (bug 1754004)
Backed out changeset cebe8d5dda34 (bug 1754004)
Backed out changeset 55b4b0c9a504 (bug 1754004)
Backed out changeset e8649de9dd22 (bug 1754004)
Backed out changeset 0f480fc861c0 (bug 1754004)
Backed out changeset e515b7edd1c8 (bug 1754004)
Backed out changeset fe90db9158ac (bug 1754004)
Backed out changeset c6388d682d48 (bug 1754004)
Backed out changeset 2374420d9fed (bug 1754004)
Backed out changeset 44dfd76472aa (bug 1754004)
Backed out changeset 000fb99de0cf (bug 1754004)
Backed out changeset 0ca1856b5fc9 (bug 1754004)
Backed out changeset 10c3683b998b (bug 1754004)
Backed out changeset 4abc98ed6b99 (bug 1759572)
Backed out changeset cdd271a5af42 (bug 1759563)
Backed out changeset fadb6cc0d81c (bug 1759569)
Backed out changeset 44be9709a93e (bug 1754031)
2022-05-06 04:28:47 +03:00
Nika Layzell
cb73e94400 Bug 1754004 - Part 3: Move RemoteLazyInputStream to its own toplevel protocol, r=asuth,necko-reviewers,dragana
This is a complete rewrite of RemoteLazyInputStream to run off of its own
toplevel protocol, rather than being managed by other protocols like
PBackground or PContent. This should improve performance thanks to no longer
needing to operate on a main or worker thread, and due to no longer needing the
migration step for the stream actor.

This also acts as a step towards no longer requiring a manager actor to
serialize input streams, as the type is now actor-agnostic, and should support
being sent over IPC between any pair of processes.

Differential Revision: https://phabricator.services.mozilla.com/D141040
2022-05-05 23:34:21 +00:00
Kagami Sascha Rosylight
b5a4737383 Bug 1767989 - Apply readability-make-member-function-const on dom/indexedDB r=dom-storage-reviewers,janv
Differential Revision: https://phabricator.services.mozilla.com/D145624
2022-05-05 18:11:55 +00:00
Sebastian Hengst
107311111f Backed out 17 changesets (bug 1696894, bug 1754004) for causing crashes e.g. bug 1767808, and hanging Gmail (bug 1767918). a=backout DONTBUILD
Backed out changeset 63f17a06eba9 (bug 1754004)
Backed out changeset 017e1552d549 (bug 1754004)
Backed out changeset 010dfd821cf3 (bug 1696894)
Backed out changeset 96a39c2ba7a3 (bug 1754004)
Backed out changeset a147df47a0e3 (bug 1754004)
Backed out changeset 9018dd592230 (bug 1754004)
Backed out changeset 234ff9e092c2 (bug 1754004)
Backed out changeset c4f1e86992b6 (bug 1754004)
Backed out changeset 51bd50b57dd5 (bug 1754004)
Backed out changeset d95e7ad0eafa (bug 1754004)
Backed out changeset 35a69828091c (bug 1754004)
Backed out changeset 6802a4326963 (bug 1754004)
Backed out changeset e40e810e18fc (bug 1754004)
Backed out changeset 82b38c12b298 (bug 1754004)
Backed out changeset 0a6cf0817bf5 (bug 1754004)
Backed out changeset 6d8e51b3e8d7 (bug 1754004)
Backed out changeset 2059c2d0d880 (bug 1754004)
2022-05-05 11:27:42 +02:00
Nika Layzell
21a97e8389 Bug 1754004 - Part 3: Move RemoteLazyInputStream to its own toplevel protocol, r=asuth,necko-reviewers,dragana
This is a complete rewrite of RemoteLazyInputStream to run off of its own
toplevel protocol, rather than being managed by other protocols like
PBackground or PContent. This should improve performance thanks to no longer
needing to operate on a main or worker thread, and due to no longer needing the
migration step for the stream actor.

This also acts as a step towards no longer requiring a manager actor to
serialize input streams, as the type is now actor-agnostic, and should support
being sent over IPC between any pair of processes.

Differential Revision: https://phabricator.services.mozilla.com/D141040
2022-05-03 23:30:33 +00:00
Butkovits Atila
bc5f86a3c7 Backed out 19 changesets (bug 1759569, bug 1754004, bug 1759563, bug 1754031, bug 1696894, bug 1759572) for causing wpt failures. CLOSED TREE
Backed out changeset 110a8dce4b5d (bug 1696894)
Backed out changeset a62dab05c6cd (bug 1754004)
Backed out changeset 7cf122f6e19f (bug 1754004)
Backed out changeset 2aa9a0a9adbc (bug 1754004)
Backed out changeset cde16b2cdbfb (bug 1754004)
Backed out changeset 452fe0a15c99 (bug 1754004)
Backed out changeset eace8d4756ef (bug 1754004)
Backed out changeset 5e1fad91e935 (bug 1754004)
Backed out changeset eb6de0b1ab8e (bug 1754004)
Backed out changeset 1ac1908ed3d0 (bug 1754004)
Backed out changeset 473cad5b22ab (bug 1754004)
Backed out changeset 1923922be138 (bug 1754004)
Backed out changeset c7966d91f89e (bug 1754004)
Backed out changeset df5ce1f6712c (bug 1754004)
Backed out changeset a3f3f9761ada (bug 1754004)
Backed out changeset c8ec86e0a33b (bug 1759572)
Backed out changeset 6c102f8e3d4a (bug 1759563)
Backed out changeset bd3a2fcf4f0c (bug 1759569)
Backed out changeset 2541d8face65 (bug 1754031)
2022-05-03 06:00:22 +03:00
Nika Layzell
9a61a1501b Bug 1754004 - Part 3: Move RemoteLazyInputStream to its own toplevel protocol, r=asuth,necko-reviewers,dragana
This is a complete rewrite of RemoteLazyInputStream to run off of its own
toplevel protocol, rather than being managed by other protocols like
PBackground or PContent. This should improve performance thanks to no longer
needing to operate on a main or worker thread, and due to no longer needing the
migration step for the stream actor.

This also acts as a step towards no longer requiring a manager actor to
serialize input streams, as the type is now actor-agnostic, and should support
being sent over IPC between any pair of processes.

Differential Revision: https://phabricator.services.mozilla.com/D141040
2022-05-02 20:44:23 +00:00
Nika Layzell
260ebb1412 Bug 1738106 - Part 3: Switch to TaskQueue::Create, r=xpcom-reviewers,necko-reviewers,media-playback-reviewers,dragana,alwu,barret
In future parts, TaskQueue will require extra initialization to be performed
which cannot happen in a constructor, as it takes references to the TaskQueue
object itself, which will require the introduction of a helper method. This
patch switches all callers of the TaskQueue constructor to use the new method.

Differential Revision: https://phabricator.services.mozilla.com/D142604
2022-05-02 20:37:34 +00:00
Jens Stutte
5f89c55426 Bug 1750525: Do not IPC_FAIL in BackgroundRequestChild::RecvPreprocess on SendContinue dispatch failure. r=dom-storage-reviewers,janv
If SendContinue(rv) fails, our channel is already dead so there is no need for another IPC_FAIL.

Differential Revision: https://phabricator.services.mozilla.com/D136134
2022-03-11 15:41:59 +00:00
Jens Stutte
de82c2e741 Bug 1750525: Adjust comment in BackgroundDatabaseChild::RecvPBackgroundIDBVersionChangeTransactionConstructor. r=dom-storage-reviewers,janv
Differential Revision: https://phabricator.services.mozilla.com/D136133
2022-03-11 15:41:59 +00:00
Jens Stutte
df854b2cbe Bug 1750525: Adjust BackgroundFactoryRequestChild::RecvPermissionChallenge IPC_FAIL cases. r=dom-storage-reviewers,janv
IPC_FAIL only when we see serious permission problems. Ignore dispatch failures as those already indicate dead actors.

Differential Revision: https://phabricator.services.mozilla.com/D136132
2022-03-11 15:41:58 +00:00
Jens Stutte
17163d1eca Bug 1750525: Recv__delete__ should IPC_FAIL only on impossible parameters. r=dom-storage-reviewers,janv
All HandleResponse variants never return false and some Recv__delete__ already ignored their return values. Let's harmonize this (should not change anything during runtime). The only remaining failure case is "Unknwon response type!" which we want to IPC_FAIL, not to MOZ_CRASH. This moves the decision about crashing into the IPC layer, depending on process type and fuzzing status.

Differential Revision: https://phabricator.services.mozilla.com/D136131
2022-03-03 08:33:15 +00:00
Nika Layzell
dc116daf53 Bug 1749059 - Remove Quantum DOM support from IPDL, r=ipc-reviewers,mccr8
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
2022-01-25 20:29:46 +00:00
Randell Jesup
8167318db4 Bug 1743895: Add names to all TaskQueues, remove no-name constructor r=nika,necko-reviewers
Differential Revision: https://phabricator.services.mozilla.com/D132638
2021-12-03 03:16:15 +00:00
Jan Varga
3e73e7ce93 Bug 1731960 - Move all Result extensions from QMResult.h to a dedicated file; r=dom-storage-reviewers,jari
Differential Revision: https://phabricator.services.mozilla.com/D126324
2021-11-30 05:05:51 +00:00
ssummar
43e270e58d Bug 1603127 - Replaced mozilla::Tuple with std::tuple and applied structured bindings in mozilla/Encoding.h. r=hsivonen
Differential Revision: https://phabricator.services.mozilla.com/D129920
2021-11-08 08:14:00 +00:00
Cristian Tuns
3b4f87f69c Backed out changeset 7e8e3747c3f8 (bug 1603127) for causing toolchains build bustages (Bug 1739589). CLOSED TREE 2021-11-05 07:23:45 -04:00
ssummar
f2f04d2ae8 Bug 1603127 - Replaced mozilla::Tuple with std::tuple and applied structured bindings in mozilla/Encoding.h. r=hsivonen
Differential Revision: https://phabricator.services.mozilla.com/D129920
2021-11-05 05:33:58 +00:00
Kagami Sascha Rosylight
1869deebf0 Bug 1736563 - Part 4: Remove redundant BFCache includes r=smaug
Differential Revision: https://phabricator.services.mozilla.com/D129332
2021-10-28 22:20:01 +00:00
ssummar
b7e03bdd6d Bug 1626517 - Replaced mozilla::Unused with mozilla::Ignore in mozilla::Decoder/mozilla::Encoder calls. r=m_kato
Differential Revision: https://phabricator.services.mozilla.com/D129022
2021-10-25 12:31:41 +00:00