[webkit-reviews] review granted: [Bug 210759] When SpeculativeLoadManager is destroyed, properly clean up its PendingFrameLoads : [Attachment 396999] Patch
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Mon Apr 20 12:28:33 PDT 2020
Darin Adler <darin at apple.com> has granted Alex Christensen
<achristensen at apple.com>'s request for review:
Bug 210759: When SpeculativeLoadManager is destroyed, properly clean up its
PendingFrameLoads
https://bugs.webkit.org/show_bug.cgi?id=210759
Attachment 396999: Patch
https://bugs.webkit.org/attachment.cgi?id=396999&action=review
--- Comment #3 from Darin Adler <darin at apple.com> ---
Comment on attachment 396999
--> https://bugs.webkit.org/attachment.cgi?id=396999
Patch
View in context: https://bugs.webkit.org/attachment.cgi?id=396999&action=review
> Source/WebKit/NetworkProcess/cache/NetworkCacheSpeculativeLoadManager.cpp:274
> + Vector<RefPtr<PendingFrameLoad>> pendingFrameLoads;
> + pendingFrameLoads.reserveInitialCapacity(m_pendingFrameLoads.size());
> + for (auto& pendingFrameLoad : m_pendingFrameLoads.values())
> + pendingFrameLoads.uncheckedAppend(pendingFrameLoad);
> + for (auto& pendingFrameLoad : pendingFrameLoads) {
You should be able to write this instead and get exactly the same effect:
for (auto& pendingFrameLoad : copyToVector(m_pendingFrameLoads.values()))
More information about the webkit-reviews
mailing list