Bug 26039 - [GTK] WebKitWebHistoryItem lifetime fixes
: [GTK] WebKitWebHistoryItem lifetime fixes
Status: RESOLVED FIXED
: WebKit
WebKit Gtk
: 528+ (Nightly build)
: PC Linux
: P2 Normal
Assigned To:
:
:
:
:
  Show dependency treegraph
 
Reported: 2009-05-27 00:50 PST by
Modified: 2009-05-28 07:54 PST (History)


Attachments
history1.patch (2.43 KB, patch)
2009-05-27 00:51 PST, Xan Lopez
jmalonzo: review+
Review Patch | Details | Formatted Diff | Diff
history2.patch (16.31 KB, patch)
2009-05-27 00:52 PST, Xan Lopez
no flags Review Patch | Details | Formatted Diff | Diff
history2.patch (16.31 KB, patch)
2009-05-27 00:53 PST, Xan Lopez
no flags Review Patch | Details | Formatted Diff | Diff
history3.patch (11.96 KB, patch)
2009-05-27 16:16 PST, Xan Lopez
gns: review+
Review Patch | Details | Formatted Diff | Diff


Note

You need to log in before you can comment on or make changes to this bug.


Description From 2009-05-27 00:50:10 PST
As discussed on IRC the lifetime management of the history items has some problems right now. The attached patches give the details.
------- Comment #1 From 2009-05-27 00:51:43 PST -------
Created an attachment (id=30698) [details]
history1.patch

Delete backforward list before page on the webview.
------- Comment #2 From 2009-05-27 00:52:19 PST -------
Created an attachment (id=30699) [details]
history2.patch

Modify management of history items.
------- Comment #3 From 2009-05-27 00:53:19 PST -------
Created an attachment (id=30700) [details]
history2.patch

Modify management of history items.
------- Comment #4 From 2009-05-27 03:37:43 PST -------
(From update of attachment 30698 [details])
r=me.
------- Comment #5 From 2009-05-27 03:56:58 PST -------
(In reply to comment #2)
> Created an attachment (id=30699) [details] [review]
> history2.patch
> 
> Modify management of history items.
> 

The original intention, and why the table is maintained by WebKitWebHistoryItem, was to share the history item between a WebBackForwardList and a *future* WebHistory. It's also the reason why I hesitated to make WebBackForwardList the sole owner of history items (i.e. the hash table maintained by back forward list).

But since I don't see WebHistory coming anytime soon, perhaps we can make the WebBackForwardList the owner of history items for now and figure this out once we have a WebHistory? Will that fix this issue?
------- Comment #6 From 2009-05-27 16:16:12 PST -------
Created an attachment (id=30719) [details]
history3.patch

A slightly less intrusive approach.
------- Comment #7 From 2009-05-27 16:28:48 PST -------
(From update of attachment 30719 [details])
> +    GObjectClass *object_class = G_OBJECT_CLASS(klass);

The only problem I could fine is this misplaced * =P
------- Comment #8 From 2009-05-28 07:54:02 PST -------
Landed both patches as 44227 and 44228. Closing.