diff options
author | wolfbeast <mcwerewolf@wolfbeast.com> | 2019-01-18 20:41:42 +0100 |
---|---|---|
committer | wolfbeast <mcwerewolf@wolfbeast.com> | 2019-01-18 21:09:15 +0100 |
commit | 978f50dda9e6f0ff6c6cb21d4caa273f3260ebc8 (patch) | |
tree | 3c0e810046d5038865d329e4f7375dae8475ab2a /xpcom/base | |
parent | 082c0d21856a87abd50e9eead87ec2dbd75b8df3 (diff) | |
download | UXP-978f50dda9e6f0ff6c6cb21d4caa273f3260ebc8.tar UXP-978f50dda9e6f0ff6c6cb21d4caa273f3260ebc8.tar.gz UXP-978f50dda9e6f0ff6c6cb21d4caa273f3260ebc8.tar.lz UXP-978f50dda9e6f0ff6c6cb21d4caa273f3260ebc8.tar.xz UXP-978f50dda9e6f0ff6c6cb21d4caa273f3260ebc8.zip |
Consolidate tracing and traversing.
Diffstat (limited to 'xpcom/base')
-rw-r--r-- | xpcom/base/nsCycleCollector.cpp | 4 | ||||
-rw-r--r-- | xpcom/base/nsCycleCollectorTraceJSHelpers.cpp | 5 |
2 files changed, 5 insertions, 4 deletions
diff --git a/xpcom/base/nsCycleCollector.cpp b/xpcom/base/nsCycleCollector.cpp index d6dc26954..01e67945d 100644 --- a/xpcom/base/nsCycleCollector.cpp +++ b/xpcom/base/nsCycleCollector.cpp @@ -2265,7 +2265,7 @@ CCGraphBuilder::BuildGraph(SliceBudget& aBudget) SetFirstChild(); if (pi->mParticipant) { - nsresult rv = pi->mParticipant->Traverse(pi->mPointer, *this); + nsresult rv = pi->mParticipant->TraverseNativeAndJS(pi->mPointer, *this); MOZ_RELEASE_ASSERT(!NS_FAILED(rv), "Cycle collector Traverse method failed"); } @@ -2539,7 +2539,7 @@ static bool MayHaveChild(void* aObj, nsCycleCollectionParticipant* aCp) { ChildFinder cf; - aCp->Traverse(aObj, cf); + aCp->TraverseNativeAndJS(aObj, cf); return cf.MayHaveChild(); } diff --git a/xpcom/base/nsCycleCollectorTraceJSHelpers.cpp b/xpcom/base/nsCycleCollectorTraceJSHelpers.cpp index 7c48002e3..f65a92e61 100644 --- a/xpcom/base/nsCycleCollectorTraceJSHelpers.cpp +++ b/xpcom/base/nsCycleCollectorTraceJSHelpers.cpp @@ -21,8 +21,9 @@ CycleCollectionNoteEdgeNameImpl(nsCycleCollectionTraversalCallback& aCallback, } void -nsScriptObjectTracer::NoteJSChild(JS::GCCellPtr aGCThing, const char* aName, - void* aClosure) +nsCycleCollectionParticipant::NoteJSChild(JS::GCCellPtr aGCThing, + const char* aName, + void* aClosure) { nsCycleCollectionTraversalCallback* cb = static_cast<nsCycleCollectionTraversalCallback*>(aClosure); |