RESOLVED FIXED 57997
Document leaks when navigating away from a scrolled page
https://bugs.webkit.org/show_bug.cgi?id=57997
Summary Document leaks when navigating away from a scrolled page
Stephanie Lewis
Reported 2011-04-06 16:18:10 PDT
Created attachment 88541 [details] testcase <rdar://problem/9187856> REGRESSION(r75555): ~5-7 MB increase in memory between iBench runs When navigating away from a page in a scrolled state the scrollbars are reset which fires a scroll event. WIth the new EventQueue for scroll events the event is never dispatched before the page detaches and keeps the Document alive. Solution is to cancel the scroll event when detaching the page. To repro: Load attached testcase Scroll navigate to about:blank close the window.
Attachments
testcase (425 bytes, text/html)
2011-04-06 16:18 PDT, Stephanie Lewis
no flags
patch (3.34 KB, patch)
2011-04-06 16:48 PDT, Stephanie Lewis
darin: review+
Stephanie Lewis
Comment 1 2011-04-06 16:48:28 PDT
Darin Adler
Comment 2 2011-04-06 16:50:24 PDT
Comment on attachment 88542 [details] patch I don’t understand this patch. It adds two new functions, but nobody calls the Document function.
Stephanie Lewis
Comment 3 2011-04-06 17:13:00 PDT
the call to to cancelEnqueuedEvents is in Document::detach. It would be more concise I suppose to just call the QueueEvent function from there and not add a function to Document.
Darin Adler
Comment 4 2011-04-06 17:52:55 PDT
Comment on attachment 88542 [details] patch View in context: https://bugs.webkit.org/attachment.cgi?id=88542&action=review > Source/WebCore/dom/Document.cpp:3553 > +void Document::cancelEnqueuedEvents() > +{ > + m_eventQueue->cancelEnqueuedEvents(); > +} I suggest just doing this in Document::detach instead of adding a function for it.
Stephanie Lewis
Comment 5 2011-04-06 18:23:57 PDT
WebKit Review Bot
Comment 6 2011-04-06 19:04:18 PDT
http://trac.webkit.org/changeset/83128 might have broken SnowLeopard Intel Release (Tests) The following tests are not passing: fast/dom/52776.html fast/text/complex-text-opacity.html fast/text/international/bidi-AN-after-L.html fast/text/international/bidi-AN-after-empty-run.html fast/text/international/bidi-CS-after-AN.html fast/text/international/bidi-mirror-he-ar.html fast/text/international/bidi-neutral-run.html platform/mac/fast/text/international/Geeza-Pro-vertical-metrics-adjustment.html
Note You need to log in before you can comment on or make changes to this bug.