Commit 595fe676 authored by falken's avatar falken Committed by Commit bot

Revert of service worker: Add CHECKs to catch if SWProcessManager isn't...

Revert of service worker: Add CHECKs to catch if SWProcessManager isn't releasing ref counts. (patchset #1 id:1 of https://codereview.chromium.org/2318443002/ )

Reason for revert:
SWProcessManager is innocent. The CHECKs aren't failing.

Original issue's description:
> service worker: Add CHECKs to catch if SWProcessManager isn't releasing ref counts.
>
> We're still not sure where the non-zero ref counts on shutdown come from.
>
> BUG=636377
>
> Committed: https://crrev.com/e7ffbf80d3b612521a7c2564b21b96695586274a
> Cr-Commit-Position: refs/heads/master@{#416596}

TBR=horo@chromium.org
# Not skipping CQ checks because original CL landed more than 1 days ago.
BUG=636377

Review-Url: https://codereview.chromium.org/2320713003
Cr-Commit-Position: refs/heads/master@{#417472}
parent 14d095b4
......@@ -193,9 +193,7 @@ void ServiceWorkerProcessManager::AllocateWorkerProcess(
return;
}
// TODO(falken): Revert to DCHECK. Temporary check for debugging
// crbug.com/639193
CHECK(!base::ContainsKey(instance_info_, embedded_worker_id))
DCHECK(!base::ContainsKey(instance_info_, embedded_worker_id))
<< embedded_worker_id << " already has a process allocated";
if (can_use_existing_process) {
......@@ -258,9 +256,7 @@ void ServiceWorkerProcessManager::ReleaseWorkerProcess(int embedded_worker_id) {
if (IsShutdown()) {
// Shutdown already released all instances.
// TODO(falken): Revert to DCHECK. Temporary check for debugging
// crbug.com/639193
CHECK(instance_info_.empty());
DCHECK(instance_info_.empty());
return;
}
......@@ -275,16 +271,12 @@ void ServiceWorkerProcessManager::ReleaseWorkerProcess(int embedded_worker_id) {
RenderProcessHost* rph = NULL;
if (info->second.site_instance.get()) {
rph = info->second.site_instance->GetProcess();
// TODO(falken): Revert to DCHECK. Temporary check for debugging
// crbug.com/639193
CHECK_EQ(info->second.process_id, rph->GetID())
DCHECK_EQ(info->second.process_id, rph->GetID())
<< "A SiteInstance's process shouldn't get destroyed while we're "
"holding a reference to it. Was the reference actually held?";
} else {
// TODO(falken): Revert to DCHECK. Temporary check for debugging
// crbug.com/639193
rph = RenderProcessHost::FromID(info->second.process_id);
CHECK(rph)
DCHECK(rph)
<< "Process " << info->second.process_id
<< " was destroyed unexpectedly. Did we actually hold a reference?";
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment