WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
182927
Crash under MIMETypeRegistry::isSupportedJavaScriptMIMEType()
https://bugs.webkit.org/show_bug.cgi?id=182927
Summary
Crash under MIMETypeRegistry::isSupportedJavaScriptMIMEType()
Chris Dumez
Reported
2018-02-19 10:19:21 PST
Crash under MIMETypeRegistry::isSupportedJavaScriptMIMEType(): Thread 6 Crashed:: WebCore: Worker 0 com.apple.WebCore 0x00007fff565cbfc0 unsigned int WTF::StringHasher::computeHashAndMaskTop8Bits<unsigned short, WTF::ASCIICaseInsensitiveHash::FoldCase<unsigned short> >(unsigned short const*, unsigned int) + 32 1 com.apple.WebCore 0x00007fff5662929e WTF::String* WTF::HashTable<WTF::String, WTF::String, WTF::IdentityExtractor, WTF::ASCIICaseInsensitiveHash, WTF::HashTraits<WTF::String>, WTF::HashTraits<WTF::String> >::lookup<WTF::IdentityHashTranslator<WTF::HashTraits<WTF::String>, WTF::ASCIICaseInsensitiveHash>, WTF::String>(WTF::String const&) + 46 2 com.apple.WebCore 0x00007fff564409cd WebCore::MIMETypeRegistry::isSupportedJavaScriptMIMEType(WTF::String const&) + 61 3 com.apple.WebCore 0x00007fff577f6bc6 WebCore::ServiceWorkerJob::didReceiveResponse(unsigned long, WebCore::ResourceResponse const&) + 134 4 com.apple.WebCore 0x00007fff577e508b WebCore::WorkerScriptLoader::didReceiveResponse(unsigned long, WebCore::ResourceResponse const&) + 539 5 com.apple.WebCore 0x00007fff57302480 WTF::Function<void (WebCore::ScriptExecutionContext&)>::CallableWrapper<WebCore::WorkerThreadableLoader::MainThreadBridge::didReceiveResponse(unsigned long, WebCore::ResourceResponse const&)::$_9>::call(WebCore::ScriptExecutionContext&) + 80 6 com.apple.WebCore 0x00007fff577e3cf0 WebCore::WorkerRunLoop::runInMode(WebCore::WorkerGlobalScope*, WebCore::ModePredicate const&, WebCore::WorkerRunLoop::WaitMode) + 416 7 com.apple.WebCore 0x00007fff577e3af0 WebCore::WorkerRunLoop::run(WebCore::WorkerGlobalScope*) + 96 8 com.apple.WebCore 0x00007fff577e6096 WebCore::WorkerThread::workerThread() + 1030 9 com.apple.JavaScriptCore 0x00007fff4c99eeb4 WTF::Thread::entryPoint(WTF::Thread::NewThreadContext*) + 228 10 com.apple.JavaScriptCore 0x00007fff4bdb49c9 WTF::wtfThreadEntryPoint(void*) + 9 11 libsystem_pthread.dylib 0x00007fff714f36c1 _pthread_body + 340 12 libsystem_pthread.dylib 0x00007fff714f356d _pthread_start + 377 13 libsystem_pthread.dylib 0x00007fff714f2c5d thread_start + 13
Attachments
Patch
(2.10 KB, patch)
2018-02-19 14:04 PST
,
Chris Dumez
no flags
Details
Formatted Diff
Diff
View All
Add attachment
proposed patch, testcase, etc.
Radar WebKit Bug Importer
Comment 1
2018-02-19 10:19:58 PST
<
rdar://problem/37675748
>
Chris Dumez
Comment 2
2018-02-19 14:04:34 PST
Created
attachment 334185
[details]
Patch
Antti Koivisto
Comment 3
2018-02-19 14:09:45 PST
Comment on
attachment 334185
[details]
Patch View in context:
https://bugs.webkit.org/attachment.cgi?id=334185&action=review
> Source/WebCore/platform/MIMETypeRegistry.cpp:502 > + if (!isMainThread()) { > + bool isSupported = false; > + callOnMainThreadAndWait([&isSupported, mimeType = mimeType.isolatedCopy()] { > + isSupported = isSupportedJavaScriptMIMEType(mimeType); > + }); > + return isSupported; > + }
It would be nice to make MIMETypeRegistry thread safe in a way that does not involve blocking on main thread.
WebKit Commit Bot
Comment 4
2018-02-19 16:20:58 PST
Comment on
attachment 334185
[details]
Patch Clearing flags on attachment: 334185 Committed
r228716
: <
https://trac.webkit.org/changeset/228716
>
WebKit Commit Bot
Comment 5
2018-02-19 16:21:00 PST
All reviewed patches have been landed. Closing bug.
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