| Index: third_party/tcmalloc/chromium/src/windows/patch_functions.cc
|
| ===================================================================
|
| --- third_party/tcmalloc/chromium/src/windows/patch_functions.cc (revision 124832)
|
| +++ third_party/tcmalloc/chromium/src/windows/patch_functions.cc (working copy)
|
| @@ -91,7 +91,7 @@
|
| #include <vector>
|
| #include <base/logging.h>
|
| #include "base/spinlock.h"
|
| -#include "gperftools/malloc_hook.h"
|
| +#include "google/malloc_hook.h"
|
| #include "malloc_hook-inl.h"
|
| #include "preamble_patcher.h"
|
|
|
| @@ -181,8 +181,6 @@
|
| kNewNothrow, kNewArrayNothrow, kDeleteNothrow, kDeleteArrayNothrow,
|
| // These are windows-only functions from malloc.h
|
| k_Msize, k_Expand,
|
| - // A MS CRT "internal" function, implemented using _calloc_impl
|
| - k_CallocCrt,
|
| kNumFunctions
|
| };
|
|
|
| @@ -406,7 +404,7 @@
|
| NULL, // kMangledNewArrayNothrow,
|
| NULL, // kMangledDeleteNothrow,
|
| NULL, // kMangledDeleteArrayNothrow,
|
| - "_msize", "_expand", "_calloc_crt",
|
| + "_msize", "_expand",
|
| };
|
|
|
| // For mingw, I can't patch the new/delete here, because the
|
| @@ -437,7 +435,6 @@
|
| #endif
|
| (GenericFnPtr)&::_msize,
|
| (GenericFnPtr)&::_expand,
|
| - (GenericFnPtr)&::calloc,
|
| };
|
|
|
| template<int T> GenericFnPtr LibcInfoWithPatchFunctions<T>::origstub_fn_[] = {
|
| @@ -460,7 +457,6 @@
|
| (GenericFnPtr)&Perftools_deletearray_nothrow,
|
| (GenericFnPtr)&Perftools__msize,
|
| (GenericFnPtr)&Perftools__expand,
|
| - (GenericFnPtr)&Perftools_calloc,
|
| };
|
|
|
| /*static*/ WindowsInfo::FunctionInfo WindowsInfo::function_info_[] = {
|
| @@ -826,7 +822,7 @@
|
| return do_realloc_with_callback(
|
| old_ptr, new_size,
|
| (void (*)(void*))origstub_fn_[kFree],
|
| - (size_t (*)(const void*))origstub_fn_[k_Msize]);
|
| + (size_t (*)(void*))origstub_fn_[k_Msize]);
|
| }
|
|
|
| template<int T>
|
| @@ -904,7 +900,7 @@
|
|
|
| template<int T>
|
| size_t LibcInfoWithPatchFunctions<T>::Perftools__msize(void* ptr) __THROW {
|
| - return GetSizeWithCallback(ptr, (size_t (*)(const void*))origstub_fn_[k_Msize]);
|
| + return GetSizeWithCallback(ptr, (size_t (*)(void*))origstub_fn_[k_Msize]);
|
| }
|
|
|
| // We need to define this because internal windows functions like to
|
|
|