Commit 5e272f8a authored by vitalybuka's avatar vitalybuka Committed by Commit bot

Revert of Temporary allocation of 20Mb before and after call to...

Revert of Temporary allocation of 20Mb before and after call to ServiceProcessControl::GetHistograms. (patchset #4 id:60001 of https://codereview.chromium.org/510563004/)

Reason for revert:
We have gathered enough evidence.

Original issue's description:
> Temporary allocation of 20Mb before and after call to ServiceProcessControl::GetHistograms.
>
> BUG=406227
>
> Committed: https://crrev.com/f89ce26c97949d224441ed45644a7d41b89bcf69
> Cr-Commit-Position: refs/heads/master@{#292325}

TBR=tapted@chromium.org
NOTREECHECKS=true
NOTRY=true
BUG=406227

Review URL: https://codereview.chromium.org/595673003

Cr-Commit-Position: refs/heads/master@{#296095}
parent 2085974e
......@@ -25,22 +25,6 @@
using content::BrowserThread;
namespace {
// Test: On Mac, launchd_msg_send tries to allocate a 10MB buffer, but doesn't
// handle errors and makes ugly crash dumps when close to OOM.
// TODO(vitalybuka): Remove after few Canary builds.
// See http://crbug.com/406227
void AllocDebugTest() {
#if defined(OS_MACOSX)
void* buffer = malloc(20 * 1024 * 1024);
CHECK(buffer);
free(buffer);
#endif // OS_MACOSX
}
} // namespace
// ServiceProcessControl implementation.
ServiceProcessControl::ServiceProcessControl() {
}
......@@ -239,7 +223,6 @@ void ServiceProcessControl::OnHistograms(
}
void ServiceProcessControl::RunHistogramsCallback() {
AllocDebugTest();
DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI));
if (!histograms_callback_.is_null()) {
histograms_callback_.Run();
......@@ -276,7 +259,6 @@ bool ServiceProcessControl::GetCloudPrintProxyInfo(
bool ServiceProcessControl::GetHistograms(
const base::Closure& histograms_callback,
const base::TimeDelta& timeout) {
AllocDebugTest();
DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI));
DCHECK(!histograms_callback.is_null());
histograms_callback_.Reset();
......
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