Bug 30465 - [Qt] QGLauncher leaks WebPage object
Summary: [Qt] QGLauncher leaks WebPage object
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebKit Qt (show other bugs)
Version: 528+ (Nightly build)
Hardware: PC All
: P2 Normal
Assignee: Antonio Gomes
URL:
Keywords: Qt
Depends on:
Blocks:
 
Reported: 2009-10-16 15:10 PDT by Antonio Gomes
Modified: 2009-10-16 20:56 PDT (History)
1 user (show)

See Also:


Attachments
(committed in r49730) patch 0.1 - make it not leak (2.29 KB, patch)
2009-10-16 15:14 PDT, Antonio Gomes
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Antonio Gomes 2009-10-16 15:10:44 PDT
object is created and never deleted.


m_item->setPage(new WebPage());
Comment 1 Antonio Gomes 2009-10-16 15:14:38 PDT
Created attachment 41334 [details]
(committed in r49730) patch 0.1 - make it not leak
Comment 2 Kenneth Rohde Christiansen 2009-10-16 15:16:48 PDT
Yes, when a page is created by the app, the app has the ownership and should destroy it.

so LGTM, though I do not like the (m_page = new WebPage) part very much, but that is just a nit.
Comment 3 Simon Hausmann 2009-10-16 18:13:23 PDT
Comment on attachment 41334 [details]
(committed in r49730) patch 0.1 - make it not leak

You could also make it a child of the mainwindow or the view, to get Qt automatically delete it. But this is okay, too :-)
Comment 4 Antonio Gomes 2009-10-16 20:55:57 PDT
r49730
Comment 5 Antonio Gomes 2009-10-16 20:56:42 PDT
Comment on attachment 41334 [details]
(committed in r49730) patch 0.1 - make it not leak

thx simon and kenneth