Bug 95777 - IndexedDB: IDBRequest leaks if IDBCursor closes and no further events fired
Summary: IndexedDB: IDBRequest leaks if IDBCursor closes and no further events fired
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: New Bugs (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Joshua Bell
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-09-04 13:43 PDT by Joshua Bell
Modified: 2012-09-04 16:33 PDT (History)
4 users (show)

See Also:


Attachments
Patch (1.84 KB, patch)
2012-09-04 13:48 PDT, Joshua Bell
no flags Details | Formatted Diff | Diff
Patch (1.85 KB, patch)
2012-09-04 15:16 PDT, Joshua Bell
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Joshua Bell 2012-09-04 13:43:16 PDT
IndexedDB: IDBRequest leaks if IDBCursor closes and no further events fired
Comment 1 Joshua Bell 2012-09-04 13:48:49 PDT
Created attachment 162098 [details]
Patch
Comment 2 Joshua Bell 2012-09-04 15:08:40 PDT
dgrogan@ - can you take a look?
Comment 3 Joshua Bell 2012-09-04 15:14:38 PDT
*sigh* - Digging back through history, finishCursor used to read:

void IDBRequest::finishCursor()
{
     m_cursorFinished = true;
     if (m_readyState != PENDING)
         m_requestFinished = true;
}

It looks like http://trac.webkit.org/changeset/123275 introduced this, and the partial reversion in http://trac.webkit.org/changeset/126254 really should have reintroduced this change, but did not. The m_readyState != PENDING actually looks better, so I'll re-up the patch.
Comment 4 Joshua Bell 2012-09-04 15:16:17 PDT
Created attachment 162107 [details]
Patch
Comment 5 David Grogan 2012-09-04 15:16:43 PDT
Comment on attachment 162107 [details]
Patch

LGTM
Comment 6 Joshua Bell 2012-09-04 15:18:07 PDT
tony@ - r?
Comment 7 WebKit Review Bot 2012-09-04 16:33:55 PDT
Comment on attachment 162107 [details]
Patch

Clearing flags on attachment: 162107

Committed r127518: <http://trac.webkit.org/changeset/127518>
Comment 8 WebKit Review Bot 2012-09-04 16:33:58 PDT
All reviewed patches have been landed.  Closing bug.