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

Unified Diff: base/allocator/generic_allocators.cc

Issue 774683003: Remove tcmalloc when not being used. Restore shim on Windows. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: add realloc death test. nits. Created 5 years, 11 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 | « base/allocator/allocator_unittest.cc ('k') | base/allocator/prep_libc.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/allocator/generic_allocators.cc
diff --git a/base/allocator/generic_allocators.cc b/base/allocator/generic_allocators.cc
index d12f3b976ac274c4526cc25ad143b130f0ac0203..2726903faf3589e5f247a34c6eaf133b5a57c110 100644
--- a/base/allocator/generic_allocators.cc
+++ b/base/allocator/generic_allocators.cc
@@ -16,7 +16,7 @@ inline void* generic_cpp_alloc(size_t size, bool nothrow) {
ptr = malloc(size);
if (ptr)
return ptr;
- if (!call_new_handler(nothrow))
+ if (!call_new_handler(nothrow, size))
break;
}
return ptr;
@@ -83,7 +83,7 @@ void* calloc(size_t n, size_t elem_size) {
return result;
}
-void cfree(void* p) __THROW {
+void cfree(void* p) {
free(p);
}
« no previous file with comments | « base/allocator/allocator_unittest.cc ('k') | base/allocator/prep_libc.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698