OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "base/win/scoped_handle.h" | 5 #include "base/win/scoped_handle.h" |
6 | 6 |
| 7 #include <stddef.h> |
| 8 |
7 #include <unordered_map> | 9 #include <unordered_map> |
8 | 10 |
9 #include "base/debug/alias.h" | 11 #include "base/debug/alias.h" |
10 #include "base/hash.h" | 12 #include "base/hash.h" |
11 #include "base/lazy_instance.h" | 13 #include "base/lazy_instance.h" |
12 #include "base/logging.h" | 14 #include "base/logging.h" |
| 15 #include "base/macros.h" |
13 #include "base/synchronization/lock_impl.h" | 16 #include "base/synchronization/lock_impl.h" |
14 | 17 |
15 extern "C" { | 18 extern "C" { |
16 __declspec(dllexport) void* GetHandleVerifier(); | 19 __declspec(dllexport) void* GetHandleVerifier(); |
17 typedef void* (*GetHandleVerifierFn)(); | 20 typedef void* (*GetHandleVerifierFn)(); |
18 } | 21 } |
19 | 22 |
20 namespace { | 23 namespace { |
21 | 24 |
22 struct HandleHash { | 25 struct HandleHash { |
(...skipping 210 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
233 void DisableHandleVerifier() { | 236 void DisableHandleVerifier() { |
234 return ActiveVerifier::Get()->Disable(); | 237 return ActiveVerifier::Get()->Disable(); |
235 } | 238 } |
236 | 239 |
237 void OnHandleBeingClosed(HANDLE handle) { | 240 void OnHandleBeingClosed(HANDLE handle) { |
238 return ActiveVerifier::Get()->OnHandleBeingClosed(handle); | 241 return ActiveVerifier::Get()->OnHandleBeingClosed(handle); |
239 } | 242 } |
240 | 243 |
241 } // namespace win | 244 } // namespace win |
242 } // namespace base | 245 } // namespace base |
OLD | NEW |