Bug 1251369. Use an AutoJSAPI that reports its own exceptions around the main runloop in workers. r=khuey
The silly leading ": " on the error messages is due to bug 1251518.
This commit is contained in:
@@ -2636,8 +2636,10 @@ WorkerThreadPrimaryRunnable::Run()
|
||||
JSAutoRequest ar(cx);
|
||||
|
||||
mWorkerPrivate->DoRunLoop(cx);
|
||||
|
||||
JS_ReportPendingException(cx);
|
||||
// The AutoJSAPI in DoRunLoop should have reported any exceptions left
|
||||
// on cx. Note that we still need the JSAutoRequest above because
|
||||
// AutoJSAPI on workers does NOT enter a request!
|
||||
MOZ_ASSERT(!JS_IsExceptionPending(cx));
|
||||
}
|
||||
|
||||
BackgroundChild::CloseForCurrentThread();
|
||||
|
||||
Reference in New Issue
Block a user