Chromium Code Reviews| Index: content/browser/renderer_host/render_process_host_impl.cc |
| diff --git a/content/browser/renderer_host/render_process_host_impl.cc b/content/browser/renderer_host/render_process_host_impl.cc |
| index a9db38c4e80d175983907baad30eec1fc6eea026..5f59494f19bd78e81b17ed23e6842458015905ad 100644 |
| --- a/content/browser/renderer_host/render_process_host_impl.cc |
| +++ b/content/browser/renderer_host/render_process_host_impl.cc |
| @@ -1399,7 +1399,12 @@ void RenderProcessHostImpl::DecrementSharedWorkerRefCount() { |
| void RenderProcessHostImpl::ForceReleaseWorkerRefCounts() { |
| DCHECK_CURRENTLY_ON(BrowserThread::UI); |
| - DCHECK(!is_worker_ref_count_disabled_); |
| + // ForceReleaseWorkerRefCounts can possibly be called twice if a new |
| + // BrowserContext is created at the same address as an one that was just |
| + // destroyed, and the new one is also soon destroyed. |
| + // https://crbug.com/661843. |
|
horo
2016/11/28 07:26:51
I think we should introduce RenderProcessHostImpl:
falken
2016/11/28 07:34:21
Hm, I considered this (see CL description) but Cle
horo
2016/11/28 08:54:40
After BrowserContext::NotifyWillBeDestroyed() is c
falken
2016/11/29 04:19:36
Hm yea I'm no longer sure of either solution. //co
|
| + if (is_worker_ref_count_disabled_) |
| + return; |
| is_worker_ref_count_disabled_ = true; |
| if (!worker_ref_count()) |
| return; |