From 6de0bcf0025517c4f31eafce162d90588c609103 Mon Sep 17 00:00:00 2001 From: "atwilson@chromium.org" Date: Wed, 17 Feb 2010 22:00:51 +0000 Subject: Fixes a race condition when a shared worker exits while one parent is loading it. Changed the shared worker startup code to assign a route ID at the time that we initially lookup the worker, and pass that same route ID in when we later try to create the worker, to gracefully handle this race condition. BUG=29243 TEST=existing tests suffice (can't reproduce race condition in tests) Review URL: http://codereview.chromium.org/600103 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@39274 0039d316-1c4b-4281-b951-d872f2087c98 --- chrome/renderer/webworker_base.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'chrome/renderer/webworker_base.h') diff --git a/chrome/renderer/webworker_base.h b/chrome/renderer/webworker_base.h index 6c031c8..b6b3da8 100644 --- a/chrome/renderer/webworker_base.h +++ b/chrome/renderer/webworker_base.h @@ -31,7 +31,8 @@ class WebWorkerBase : public IPC::Channel::Listener { bool is_shared, const string16& name, const string16& user_agent, - const string16& source_code); + const string16& source_code, + int pending_route_id); // Returns true if the worker is running (can send messages to it). bool IsStarted(); -- cgit v1.1