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

Unified Diff: base/allocator/allocator_impl_win.h

Issue 2138173002: Hookup the generic heap intercept for Windows. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix dangling use of ::g_win_new_mode. Created 4 years, 5 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
Index: base/allocator/allocator_impl_win.h
diff --git a/base/allocator/allocator_impl_win.h b/base/allocator/allocator_impl_win.h
new file mode 100644
index 0000000000000000000000000000000000000000..1f7167b8e0ca84a016cdef6d1019ec79ee503ab5
--- /dev/null
+++ b/base/allocator/allocator_impl_win.h
@@ -0,0 +1,27 @@
+// Copyright (c) 2012 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#include <limits.h>
+#include <malloc.h>
+#include <new.h>
+#include <windows.h>
+#include <stddef.h>
+
+
+namespace base {
Primiano Tucci (use gerrit) 2016/07/12 14:51:05 I'd add a TODO to this file saying that once the u
Sigurður Ásgeirsson 2016/07/14 19:04:27 Done.
+namespace allocator {
+
+extern bool g_is_win_shim_layer_initialized;
+
+void* WinHeapMalloc(size_t size);
+void WinHeapFree(void* size);
+void* WinHeapRealloc(void* ptr, size_t size);
+void* WinHeapCalloc(size_t n, size_t elem_size);
+
+// Call the new handler, if one has been set.
+// Returns true on successfully calling the handler, false otherwise.
+bool WinCallNewHandler(size_t size);
+
+} // namespace allocator
+} // namespace base

Powered by Google App Engine
This is Rietveld 408576698