Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(53)

Unified Diff: Source/core/workers/WorkerThread.cpp

Issue 692003002: ServiceWorker: Registering a malformed script should fail [1/3] (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 6 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: Source/core/workers/WorkerThread.cpp
diff --git a/Source/core/workers/WorkerThread.cpp b/Source/core/workers/WorkerThread.cpp
index 4afc1f86c0dd84d85880c9f0ca1d31ee3f73c104..f8fa2454609bcb8398f6b7bd4b91866cf09861a9 100644
--- a/Source/core/workers/WorkerThread.cpp
+++ b/Source/core/workers/WorkerThread.cpp
@@ -320,9 +320,12 @@ void WorkerThread::initialize()
if (!script->isExecutionForbidden())
script->initializeContextIfNeeded();
InspectorInstrumentation::willEvaluateWorkerScript(workerGlobalScope(), startMode);
- script->evaluate(ScriptSourceCode(sourceCode, scriptURL));
+ bool result = script->evaluate(ScriptSourceCode(sourceCode, scriptURL));
m_workerGlobalScope->didEvaluateWorkerScript();
+ // Notify proxy that a worker script has been evaluated.
+ m_workerReportingProxy.workerScriptEvaluated(result);
+
postInitialize();
postDelayedTask(createSameThreadTask(&WorkerThread::idleHandler, this), kShortIdleHandlerDelayMs);

Powered by Google App Engine
This is Rietveld 408576698