[Webkit-unassigned] [Bug 19786] New: LEAK when rapidly closing multiple tabs while they are still loading content

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Thu Jun 26 21:19:28 PDT 2008


https://bugs.webkit.org/show_bug.cgi?id=19786

           Summary: LEAK when rapidly closing multiple tabs while they are
                    still loading content
           Product: WebKit
           Version: 525.x (Safari 3.1)
          Platform: Macintosh
        OS/Version: Mac OS X 10.5
            Status: UNCONFIRMED
          Severity: Normal
          Priority: P2
         Component: New Bugs
        AssignedTo: webkit-unassigned at lists.webkit.org
        ReportedBy: dylanryan at mac.com


When multiple tabs are opened and then closed before they are loaded, I see
several memory leaks. Most recently, the following (although exactly what is
leaked seems to vary somewhat)

1 BrowserDocument object, 1 WebView object, 1 WebFrame object, 1 WebDataSource
object, 1 WebFrameView object, 1 WebHTMLRepresentation object, 1 JavaScript
global object.



To reproduce
1) Close all safari windows except one.
2) If you do not have a bookmark folder with 10 or more bookmarks in it, you'll
need to make one, preferably with a few pages that take a while to load fully
near the end of the list and a page that loads fast first (this is not
required, it just helps). 
3) Hover your fingers over Cmd-W, because you are going to need to be fast on
the uptake here.
4) Open the bookmark folder in tabs (Cmd-click or select from the bottom of the
folder list)
5) As soon as ANY content is displayed on the first page (use a fast page to
ensure that the other pages are still loading!), press and hold Cmd-W until all
tabs and finally the window are closed. Note that if you do not HOLD Cmd-W down
the entire time, it happens much less often (if at all). 

The "Leaks" window comes up, and often displays again several times after you
press OK (it seems like each tab may leak that or something similar)


Another run of this to make sure it still happens in r34822 (it does), and I
got the following (the window displaying this information re-opened 5 times,
FWIW)

1 BrowserDocument object, 1 WebView object, 1 WebFrame object, 2 WebDataSource
objects, 1 WebFrameView object, 2 WebHTMLRepresentation objects, 2 JavaScript
global objects.




It should work with any collection of webpages so long as at least a couple are
still loading content (or is still trying to start loading content) when it is
closed and so long as the first tab loads at least a little data
(realistically, ANY tab needs to load some data, but it is easiest to tell on
the first tab, obviously). I can post the bookmarks in a folder I have that
always reproduces this if need be, but if it isn't needed I won't. It has
worked with every random collection of webpages I have tried it with. 


This is not a regression, also happens in shipping safari 3.1.1 on 10.5.3.
shipping safari's leak message:

1 BrowserDocument object, 1 WebView object, 1 WebFrame object, 1 WebDataSource
object, 1 WebFrameView object, 1 WebHTMLRepresentation object, 1 WebBridge
object.


Again, what exactly is leaked seems to vary (probably depending on what pages
are loading, loaded, or trying to load at the time, etc), but it is always a
long list like that. 


This does NOT happen if you "close all tabs" (Shift-Cmd-W), even in the same
circumstances. I just never REMEMBER that keyboard shortcut exists, so if I
accidentally open a tab group i usually just hold Cmd-W.


-- 
Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.



More information about the webkit-unassigned mailing list