WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
Bug 69380
toURLRef() in WKSharedAPICast.h should return null for a null string
https://bugs.webkit.org/show_bug.cgi?id=69380
Summary
toURLRef() in WKSharedAPICast.h should return null for a null string
Ada Chan
Reported
2011-10-04 15:05:49 PDT
toURLRef() in WKSharedAPICast.h should return null for a null string. Looks like it's just missing a "return" here: if (!string) ProxyingRefPtr<WebURL>(0);
Attachments
Patch: Add the missing return for the null string case.
(1.22 KB, patch)
2011-10-04 15:29 PDT
,
Ada Chan
jhoneycutt
: review+
Details
Formatted Diff
Diff
View All
Add attachment
proposed patch, testcase, etc.
Ada Chan
Comment 1
2011-10-04 15:29:52 PDT
Created
attachment 109705
[details]
Patch: Add the missing return for the null string case.
Ada Chan
Comment 2
2011-10-04 15:46:41 PDT
Committed:
http://trac.webkit.org/changeset/96656
Adam Roben (:aroben)
Comment 3
2011-10-05 04:02:02 PDT
What's the user-visible or developer-visible effect of this bug? In general I think it's a lot more useful to have bugs describe symptoms rather than describing changes we'd like to make to the code. Is it possible to write a regression test for this?
Ada Chan
Comment 4
2011-10-05 10:39:52 PDT
(In reply to
comment #3
)
> What's the user-visible or developer-visible effect of this bug? In general I think it's a lot more useful to have bugs describe symptoms rather than describing changes we'd like to make to the code.
If WKURLCopyCFURL() is called on the resulting WKURLRef later, it'll assert in ASSERT(!toImpl(URLRef)->string().isNull()); because the string is null.
> Is it possible to write a regression test for this?
I'll look into writing a TestWebKitAPI test for this. Thanks for the suggestion!
Ada Chan
Comment 5
2011-10-14 17:14:37 PDT
(In reply to
comment #3
)
> What's the user-visible or developer-visible effect of this bug? In general I think it's a lot more useful to have bugs describe symptoms rather than describing changes we'd like to make to the code. > > Is it possible to write a regression test for this?
Coming up with a test for this is not as straightforward as I imagined, since we can't call toURLRef() directly from a TestWebKitAPI test. I've filed
https://bugs.webkit.org/show_bug.cgi?id=70159
to track coming up with a test for this.
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