diff --git a/toolkit/components/places/src/nsNavHistoryResult.cpp b/toolkit/components/places/src/nsNavHistoryResult.cpp index 9cc01be008a..bba7ecf9285 100644 --- a/toolkit/components/places/src/nsNavHistoryResult.cpp +++ b/toolkit/components/places/src/nsNavHistoryResult.cpp @@ -3847,12 +3847,13 @@ NS_IMPL_CYCLE_COLLECTION_UNLINK_END static PLDHashOperator TraverseBookmarkFolderObservers(nsTrimInt64HashKey::KeyType aKey, - nsNavHistoryResult::FolderObserverList* &aData, - void *aClosure) + nsNavHistoryResult::FolderObserverList*& aData, + void* aUserArg) { nsCycleCollectionTraversalCallback* cb = - static_cast(aClosure); - for (PRUint32 i = 0; i < aData->Length(); ++i) { + static_cast(aUserArg); + PRUint32 i, count = aData->Length(); + for (i = 0; i < count; ++i) { NS_CYCLE_COLLECTION_NOTE_EDGE_NAME(*cb, "mBookmarkFolderObservers value[i]"); nsNavHistoryResultNode* node = aData->ElementAt(i); @@ -3861,24 +3862,10 @@ TraverseBookmarkFolderObservers(nsTrimInt64HashKey::KeyType aKey, return PL_DHASH_NEXT; } -static PLDHashOperator -TraversePropertyBags(nsISupportsHashKey::KeyType aKey, - nsCOMPtr &aData, - void *aClosure) -{ - nsCycleCollectionTraversalCallback* cb = - static_cast(aClosure); - NS_CYCLE_COLLECTION_NOTE_EDGE_NAME(cb, "mPropertyBags key"); - cb->NoteXPCOMChild(aKey); - - return PL_DHASH_NEXT; -} - NS_IMPL_CYCLE_COLLECTION_TRAVERSE_BEGIN(nsNavHistoryResult) NS_IMPL_CYCLE_COLLECTION_TRAVERSE_NSCOMPTR_AMBIGUOUS(mRootNode, nsINavHistoryContainerResultNode) NS_IMPL_CYCLE_COLLECTION_TRAVERSE_NSCOMPTR(mView) tmp->mBookmarkFolderObservers.Enumerate(&TraverseBookmarkFolderObservers, &cb); - tmp->mPropertyBags.Enumerate(&TraversePropertyBags, &cb); NS_IMPL_CYCLE_COLLECTION_TRAVERSE_NSTARRAY_MEMBER(mAllBookmarksObservers, nsNavHistoryQueryResultNode) NS_IMPL_CYCLE_COLLECTION_TRAVERSE_NSTARRAY_MEMBER(mHistoryObservers, nsNavHistoryQueryResultNode) NS_IMPL_CYCLE_COLLECTION_TRAVERSE_END