Bug 78104

Summary: [GTK] Fix a crash when WebKitWebView is created without a WebContext
Product: WebKit Reporter: Carlos Garcia Campos <cgarcia>
Component: WebKit2Assignee: Nobody <webkit-unassigned>
Status: RESOLVED FIXED    
Severity: Normal CC: gustavo, pnormand, webkit.review.bot
Priority: P2 Keywords: Gtk
Version: 528+ (Nightly build)   
Hardware: PC   
OS: Linux   
Attachments:
Description Flags
Patch pnormand: review+

Description Carlos Garcia Campos 2012-02-08 04:50:00 PST
WebContext is a construct only property of WebKitWebView. webkit_web_view_new() passes the default web context as g_object_new parameter. If a web view is created with g_object_new without passing the web context parameter (which is a normal situation when creating objects derived from WebKitWebView), the default value for GObject propetrties is set (NULL). In webkitWebViewConstructed we assume the view already has a web context and it crashes if it hasn't.
Comment 1 Carlos Garcia Campos 2012-02-08 04:52:10 PST
Created attachment 126060 [details]
Patch
Comment 2 WebKit Review Bot 2012-02-08 04:55:34 PST
Thanks for the patch. If this patch contains new public API please make sure it follows the guidelines for new WebKit2 GTK+ API. See http://trac.webkit.org/wiki/WebKitGTK/AddingNewWebKit2API
Comment 3 Carlos Garcia Campos 2012-02-08 08:31:33 PST
Committed r107092: <http://trac.webkit.org/changeset/107092>