WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
98433
Crash in Safari at com.apple.JavaScriptCore: WTF::StringImpl::is8Bit const + 12
https://bugs.webkit.org/show_bug.cgi?id=98433
Summary
Crash in Safari at com.apple.JavaScriptCore: WTF::StringImpl::is8Bit const + 12
Michael Saboff
Reported
2012-10-04 11:34:33 PDT
Crash running safari extension tests. Looks like is8Bit() is called on a String without a StringImpl. <
rdar://problem/12433701
>
Attachments
Patch
(1.63 KB, patch)
2012-10-04 11:48 PDT
,
Michael Saboff
jberlin
: review+
Details
Formatted Diff
Diff
View All
Add attachment
proposed patch, testcase, etc.
Michael Saboff
Comment 1
2012-10-04 11:48:15 PDT
Created
attachment 167152
[details]
Patch
Jessie Berlin
Comment 2
2012-10-04 11:51:15 PDT
Comment on
attachment 167152
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=167152&action=review
> Source/JavaScriptCore/ChangeLog:11 > + (JSValueMakeFromJSONString):
You should also mention that characters16() does the is8Bit() check, which is why you changed it to characters().
Michael Saboff
Comment 3
2012-10-04 13:27:35 PDT
Committed
r130424
: <
http://trac.webkit.org/changeset/130424
>
Michael Saboff
Comment 4
2012-10-04 17:42:59 PDT
This is actually fixing the symptom of a problem in <
http://trac.webkit.org/changeset/130344
> and the follow-on <
http://trac.webkit.org/changeset/130413
>. It appears that we are turning a null string into an empty string in OpaqueJSString.cpp. See
https://bugs.webkit.org/show_bug.cgi?id=98417
.
Michael Saboff
Comment 5
2012-10-10 10:16:44 PDT
Reopened because
https://bugs.webkit.org/show_bug.cgi?id=98417
"After
r130344
, OpaqueJSString() creates an empty string which should be a null string" was the source of this particular crash. However the change in this patch (
r130424
) is actually needed. Consider the case: JSStringRef nullJSON = JSStringCreateWithUTF8CString(0); JSValueRef nullJSONObject = JSValueMakeFromJSONString(context, nullJSON); nullJSON will have a null string which would cause the code before this patch to crash. The case above has been added to testapi.c in
r130832
: <
http://trac.webkit.org/changeset/130832
>.
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