111
|
1 //===-- sanitizer_dbghelp.h ------------------------------*- C++ -*-===//
|
|
2 //
|
|
3 // This file is distributed under the University of Illinois Open Source
|
|
4 // License. See LICENSE.TXT for details.
|
|
5 //
|
|
6 //===----------------------------------------------------------------------===//
|
|
7 //
|
|
8 // Wrappers for lazy loaded dbghelp.dll. Provides function pointers and a
|
|
9 // callback to initialize them.
|
|
10 //
|
|
11 //===----------------------------------------------------------------------===//
|
|
12
|
|
13 #ifndef SANITIZER_SYMBOLIZER_WIN_H
|
|
14 #define SANITIZER_SYMBOLIZER_WIN_H
|
|
15
|
|
16 #if !SANITIZER_WINDOWS
|
|
17 #error "sanitizer_dbghelp.h is a Windows-only header"
|
|
18 #endif
|
|
19
|
|
20 #define WIN32_LEAN_AND_MEAN
|
|
21 #include <windows.h>
|
|
22 #include <dbghelp.h>
|
|
23
|
|
24 namespace __sanitizer {
|
|
25
|
|
26 extern decltype(::StackWalk64) *StackWalk64;
|
|
27 extern decltype(::SymCleanup) *SymCleanup;
|
|
28 extern decltype(::SymFromAddr) *SymFromAddr;
|
|
29 extern decltype(::SymFunctionTableAccess64) *SymFunctionTableAccess64;
|
|
30 extern decltype(::SymGetLineFromAddr64) *SymGetLineFromAddr64;
|
|
31 extern decltype(::SymGetModuleBase64) *SymGetModuleBase64;
|
|
32 extern decltype(::SymGetSearchPathW) *SymGetSearchPathW;
|
|
33 extern decltype(::SymInitialize) *SymInitialize;
|
|
34 extern decltype(::SymSetOptions) *SymSetOptions;
|
|
35 extern decltype(::SymSetSearchPathW) *SymSetSearchPathW;
|
|
36 extern decltype(::UnDecorateSymbolName) *UnDecorateSymbolName;
|
|
37
|
|
38 } // namespace __sanitizer
|
|
39
|
|
40 #endif // SANITIZER_SYMBOLIZER_WIN_H
|