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

Unified Diff: test/mjsunit/d8-worker.js

Issue 1208733002: Fix cluster-fuzz regression when getting message from Worker (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: don't remove Worker from workers_ on terminate Created 5 years, 6 months 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
« no previous file with comments | « src/d8.cc ('k') | test/mjsunit/d8-worker-spawn-worker.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: test/mjsunit/d8-worker.js
diff --git a/test/mjsunit/d8-worker.js b/test/mjsunit/d8-worker.js
index 807791717e1f6f7f047a9cc718468ad4f138a176..ef02ca5b405815ca5252886b4cfe46d4ead4dfbc 100644
--- a/test/mjsunit/d8-worker.js
+++ b/test/mjsunit/d8-worker.js
@@ -128,4 +128,12 @@ if (this.Worker) {
assertEquals("DONE", w.getMessage());
w.terminate();
+
+
+ // Make sure that the main thread doesn't block forever in getMessage() if
+ // the worker dies without posting a message.
+ function f2() {}
+ var w2 = new Worker(f2);
+ var msg = w2.getMessage();
+ assertEquals(undefined, msg);
}
« no previous file with comments | « src/d8.cc ('k') | test/mjsunit/d8-worker-spawn-worker.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698