WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
17948
Exception in -[WebDataSource webArchive]
https://bugs.webkit.org/show_bug.cgi?id=17948
Summary
Exception in -[WebDataSource webArchive]
Michael Tsai
Reported
2008-03-19 07:06:16 PDT
I've seen several cases where WebKit raises an exception: -[NSCFArray insertObject:atIndex:]: attempt to insert nil when my code calls [[[webView mainFrame] dataSource] webArchive]. I've been able to reproduce this only rarely on my Mac, but I have a customer for whom it happens 100% of the time, no matter the page. As far as I can tell, the exception is being raised in -[WebDataSource subresources]. It looks like the WebResource that's being created in the loop is returning nil from its -init method. While there may be an interesting and significant reason for that, I suggest that -subresources refrain from adding nil objects to the array so that at least a partial Web archive can be returned.
Attachments
Add attachment
proposed patch, testcase, etc.
David Kilzer (:ddkilzer)
Comment 1
2008-11-24 13:28:18 PST
Does your customer have any third-party "extensions" (haxies, input managers, etc.) installed for Safari?
Michael Tsai
Comment 2
2008-11-24 13:41:11 PST
No.
David Kilzer (:ddkilzer)
Comment 3
2008-11-24 20:15:58 PST
Could you have the customer recreate the crash and post a crash log to this bug? If you would prefer not to post a crash log of your application here, please create a bug using <
https://bugreport.apple.com/
> and report the 7-digit bug number here.
Michael Tsai
Comment 4
2008-11-25 06:19:35 PST
It's not crashing for the customer, just raising an exception that's caught in my code.
David Kilzer (:ddkilzer)
Comment 5
2008-11-25 10:16:58 PST
(In reply to
comment #4
)
> It's not crashing for the customer, just raising an exception that's caught in > my code.
Is there any way you could provide a stack trace when the exception is caught? Can you provide a reproducible test case using a local copy of the customer's web page? BTW, what revision(s) of WebKit are you using? Does this work on a nightly WebKit build? After re-reading the description, this sounds related to
Bug 22466
. I think the code in WebKit -[WebDataSource subresources] has moved to DocumentLoader::subresources() in tip-of-tree (ToT) WebKit, though.
Michael Tsai
Comment 6
2008-11-25 11:16:14 PST
One of the problem Web pages was:
http://www.faqts.com/knowledge_base/index.phtml/fid/199/
I am no longer able to reproduce the problem using the WebKit from Safari 3.2.1.
David Kilzer (:ddkilzer)
Comment 7
2008-11-25 11:26:46 PST
(In reply to
comment #6
)
> One of the problem Web pages was: > >
http://www.faqts.com/knowledge_base/index.phtml/fid/199/
> > I am no longer able to reproduce the problem using the WebKit from Safari > 3.2.1.
Can this bug be closed then?
Michael Tsai
Comment 8
2008-11-25 12:29:34 PST
Yes.
David Kilzer (:ddkilzer)
Comment 9
2008-11-25 13:47:30 PST
See also
Bug 17151
. Closing per
Comment #8
.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug