1 // RUN: %clangxx_asan -O0 %s -o %t && not %run %t 2>&1 | FileCheck %s
2
3 #include <windows.h>
4 #include <dbghelp.h>
5
main()6 int main() {
7 // Make sure the RTL recovers from "no options enabled" dbghelp setup.
8 SymSetOptions(0);
9
10 // Make sure the RTL recovers from "fInvadeProcess=FALSE".
11 if (!SymInitialize(GetCurrentProcess(), 0, FALSE))
12 return 42;
13
14 *(volatile int*)0 = 42;
15 // CHECK: ERROR: AddressSanitizer: access-violation on unknown address
16 // CHECK-NEXT: {{WARNING: .*DbgHelp}}
17 // CHECK: {{#0 0x.* in main.*report_after_syminitialize.cc:}}[[@LINE-3]]
18 // CHECK: AddressSanitizer can not provide additional info.
19 }
20