Bug 24212

Summary: Crashes when given the URI of a directory, or other non-regular files
Product: WebKit Reporter: Gustavo Noronha (kov) <gns>
Component: WebKitGTKAssignee: Gustavo Noronha (kov) <gns>
Status: RESOLVED FIXED    
Severity: Normal Keywords: Gtk
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: PC   
OS: All   
Attachments:
Description Flags
proposed fix
zecke: review+
errors cleanup zecke: review+

Description Gustavo Noronha (kov) 2009-02-26 15:39:14 PST
The crash happens because in this specific case an error is reported, but the GError that is given to networkErrorForFile is NULL, and error->message is accessed unconditionally.
Comment 1 Gustavo Noronha (kov) 2009-02-26 15:40:13 PST
Created attachment 28049 [details]
proposed fix
Comment 2 Holger Freyther 2009-03-01 07:26:50 PST
Comment on attachment 28049 [details]
proposed fix

Yeah. we leak the GError in the caller though.
Comment 3 Gustavo Noronha (kov) 2009-03-01 07:51:35 PST
Created attachment 28143 [details]
errors cleanup
Comment 4 Holger Freyther 2009-03-01 08:12:19 PST
Comment on attachment 28143 [details]
errors cleanup

looks good, please split it in two parts.
Comment 5 Gustavo Noronha (kov) 2009-03-01 08:22:24 PST
Landed as r41332 and r41333.