Bug 109225 - [Gtk] WebKit2 crashes when loading pages with http 304 code.
Summary: [Gtk] WebKit2 crashes when loading pages with http 304 code.
Status: RESOLVED DUPLICATE of bug 109287
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebKitGTK (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Nobody
URL: http://renevier.net/misc/webkit_10922...
Keywords:
Depends on:
Blocks:
 
Reported: 2013-02-07 13:23 PST by arno.
Modified: 2013-02-08 07:40 PST (History)
4 users (show)

See Also:


Attachments
crashtest source (245 bytes, application/x-php)
2013-02-07 13:25 PST, arno.
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description arno. 2013-02-07 13:23:35 PST
Hi, when loading a page with a 304 code from cache, MiniBrowser crashes.
This happens because in that case, receiveData happens before receiveResponse.
Then, in that case, setCertificateToMainResource is called before a response has been set to the webresource. So, webkitURIResponseSetCertificateInfo(webkit_web_resource_get_response(priv->mainResource.get()), results in a null parameter being used in webkitURIResponseSetCertificateInfo).

Here is the crash backtrace:

#0  0xb6918bd9 in webkitURIResponseSetCertificateInfo(_WebKitURIResponse*, WebKit::WebCertificateInfo*) ()
   from /home/arno/webkit/WebKit.upstream/WebKitBuild/Release/.libs/libwebkit2gtk-3.0.so.0
#1  0xb6922c45 in setCertificateToMainResource(_WebKitWebView*) () from /home/arno/webkit/WebKit.upstream/WebKitBuild/Release/.libs/libwebkit2gtk-3.0.so.0
#2  0xb6928dcd in webkitWebViewLoadChanged(_WebKitWebView*, WebKitLoadEvent) () from /home/arno/webkit/WebKit.upstream/WebKitBuild/Release/.libs/libwebkit2gtk-3.0.so.0
#3  0xb690a34b in didCommitLoadForFrame(OpaqueWKPage const*, OpaqueWKFrame const*, void const*, void const*) ()
   from /home/arno/webkit/WebKit.upstream/WebKitBuild/Release/.libs/libwebkit2gtk-3.0.so.0
#4  0xb6978912 in WebKit::WebLoaderClient::didCommitLoadForFrame(WebKit::WebPageProxy*, WebKit::WebFrameProxy*, WebKit::APIObject*) ()
   from /home/arno/webkit/WebKit.upstream/WebKitBuild/Release/.libs/libwebkit2gtk-3.0.so.0
#5  0xb698c20e in WebKit::WebPageProxy::didCommitLoadForFrame(unsigned long long, WTF::String const&, bool, unsigned int, WebKit::PlatformCertificateInfo const&, CoreIPC::MessageDecoder&) () from /home/arno/webkit/WebKit.upstream/WebKitBuild/Release/.libs/libwebkit2gtk-3.0.so.0
#6  0xb6a4aeb8 in void CoreIPC::handleMessageVariadic<Messages::WebPageProxy::DidCommitLoadForFrame, WebKit::WebPageProxy, void (WebKit::WebPageProxy::*)(unsigned long long, WTF::String const&, bool, unsigned int, WebKit::PlatformCertificateInfo const&, CoreIPC::MessageDecoder&)>(CoreIPC::MessageDecoder&, WebKit::WebPageProxy*, void (WebKit::WebPageProxy::*)(unsigned long long, WTF::String const&, bool, unsigned int, WebKit::PlatformCertificateInfo const&, CoreIPC::MessageDecoder&)) ()
   from /home/arno/webkit/WebKit.upstream/WebKitBuild/Release/.libs/libwebkit2gtk-3.0.so.0
#7  0xb6a4a458 in WebKit::WebPageProxy::didReceiveWebPageProxyMessage(CoreIPC::Connection*, CoreIPC::MessageDecoder&) ()
   from /home/arno/webkit/WebKit.upstream/WebKitBuild/Release/.libs/libwebkit2gtk-3.0.so.0
#8  0xb69850a7 in WebKit::WebPageProxy::didReceiveMessage(CoreIPC::Connection*, CoreIPC::MessageDecoder&) ()
   from /home/arno/webkit/WebKit.upstream/WebKitBuild/Release/.libs/libwebkit2gtk-3.0.so.0
#9  0xb69a230c in WebKit::WebProcessProxy::didReceiveMessage(CoreIPC::Connection*, CoreIPC::MessageDecoder&) ()
   from /home/arno/webkit/WebKit.upstream/WebKitBuild/Release/.libs/libwebkit2gtk-3.0.so.0
Comment 1 arno. 2013-02-07 13:25:00 PST
loading the above url twice in a row will crash MiniBrowser.
Comment 2 arno. 2013-02-07 13:25:19 PST
Created attachment 187164 [details]
crashtest source
Comment 3 Sergio Villar Senin 2013-02-08 07:40:51 PST
Although this was reported first, I'm setting this as dup of the other because there is a patch available

*** This bug has been marked as a duplicate of bug 109287 ***