WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
183013
ServiceWorkerJob::m_lastResponse is unneeded
https://bugs.webkit.org/show_bug.cgi?id=183013
Summary
ServiceWorkerJob::m_lastResponse is unneeded
youenn fablet
Reported
2018-02-21 12:47:38 PST
ServiceWorkerJob::m_lastResponse is unneeded
Attachments
Patch
(2.12 KB, patch)
2018-02-21 12:49 PST
,
youenn fablet
no flags
Details
Formatted Diff
Diff
View All
Add attachment
proposed patch, testcase, etc.
youenn fablet
Comment 1
2018-02-21 12:49:27 PST
Created
attachment 334405
[details]
Patch
youenn fablet
Comment 2
2018-02-21 13:08:20 PST
This could fix the following crash since m_lastResponse is the only ResourceResponse: Thread 5 Crashed ↩:: WebCore: Worker 0 com.apple.JavaScriptCore 0x00007fff301cd4c0 WTF::StringImpl::~StringImpl() + 80 1 com.apple.JavaScriptCore 0x00007fff301cd45e WTF::StringImpl::destroy(WTF::StringImpl*) + 14 2 com.apple.WebCore 0x00007fff3a8133c8 WebCore::ResourceResponseBase::~ResourceResponseBase() + 184 3 com.apple.WebCore 0x00007fff3bc2f89b WebCore::ServiceWorkerJob::~ServiceWorkerJob() + 59 4 com.apple.WebCore 0x00007fff3bc2f94e WebCore::ServiceWorkerJob::~ServiceWorkerJob() + 14 5 com.apple.WebCore 0x00007fff3bc2d27c WebCore::ServiceWorkerContainer::jobResolvedWithRegistration(WebCore::ServiceWorkerJob&, WebCore::ServiceWorkerRegistrationData&&, WebCore::ShouldNotifyWhenResolved) + 2444 6 com.apple.WebCore 0x00007fff3bc26c98 WTF::Function<void (WebCore::ScriptExecutionContext&)>::CallableWrapper<WebCore::SWClientConnection::postTaskForJob(WTF::ObjectIdentifier<WebCore::ServiceWorkerJobIdentifierType>, WebCore::SWClientConnection::IsJobComplete, WTF::Function<void (WebCore::ServiceWorkerJob&)>&&)::$_2>::call(WebCore::ScriptExecutionContext&) + 72 7 com.apple.WebCore 0x00007fff3bc1cd10 WebCore::WorkerRunLoop::runInMode(WebCore::WorkerGlobalScope*, WebCore::ModePredicate const&, WebCore::WorkerRunLoop::WaitMode) + 416 8 com.apple.WebCore 0x00007fff3bc1cb10 WebCore::WorkerRunLoop::run(WebCore::WorkerGlobalScope*) + 96 9 com.apple.WebCore 0x00007fff3bc1f0d9 WebCore::WorkerThread::workerThread() + 1033 10 com.apple.JavaScriptCore 0x00007fff30db8f44 WTF::Thread::entryPoint(WTF::Thread::NewThreadContext*) + 228 11 com.apple.JavaScriptCore 0x00007fff301cdbd9 WTF::wtfThreadEntryPoint(void*) + 9 12 libsystem_pthread.dylib 0x00007fff5597e661 _pthread_body + 340 13 libsystem_pthread.dylib 0x00007fff5597e50d _pthread_start + 377 14 libsystem_pthread.dylib 0x00007fff5597dbf9 thread_start + 13 That said, m_lastResponse is given by a WorkerThreadableLoaderClient callback so the response should already be isolated. Maybe there is a bigger issue and ServiceWorkerJob is not always deleted in the right thread?
Chris Dumez
Comment 3
2018-02-21 13:10:14 PST
Comment on
attachment 334405
[details]
Patch r=me if the bots are happy.
WebKit Commit Bot
Comment 4
2018-02-21 13:51:38 PST
Comment on
attachment 334405
[details]
Patch Clearing flags on attachment: 334405 Committed
r228895
: <
https://trac.webkit.org/changeset/228895
>
WebKit Commit Bot
Comment 5
2018-02-21 13:51:40 PST
All reviewed patches have been landed. Closing bug.
Radar WebKit Bug Importer
Comment 6
2018-02-21 13:52:27 PST
<
rdar://problem/37759608
>
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