Use WeakHashSet<Page> instead of HashSet<Page*>
Created attachment 416687 [details] Patch
<rdar://problem/72728030>
Comment on attachment 416687 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=416687&action=review > Source/WebKit/WebProcess/InjectedBundle/InjectedBundle.cpp:173 > + for (const auto& page : PageGroup::pageGroup(pageGroup->identifier())->pages()) Not sure we should have the const here. For one thing, changing the settings for a page doesn’t seem very "const". > Source/WebKit/WebProcess/InjectedBundle/InjectedBundle.cpp:289 > + for (const auto& page : PageGroup::pageGroup(pageGroup->identifier())->pages()) Ditto. > Source/WebKit/WebProcess/InjectedBundle/InjectedBundle.cpp:345 > + for (const auto& page : PageGroup::pageGroup(pageGroup->identifier())->pages()) { > + for (const auto* frame = &page.mainFrame(); frame; frame = frame->tree().traverseNext()) { Could omit const here too.
Created attachment 417016 [details] Patch
http://trac.webkit.org/r271153