[asan] Add flushes to try to fix test
git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@335089 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/test/asan/TestCases/Windows/user-exception.cc b/test/asan/TestCases/Windows/user-exception.cc
index 6824115..4cff23f 100644
--- a/test/asan/TestCases/Windows/user-exception.cc
+++ b/test/asan/TestCases/Windows/user-exception.cc
@@ -20,7 +20,7 @@
DWORD exception_code = info->ExceptionRecord->ExceptionCode;
if (exception_code == EXCEPTION_ACCESS_VIOLATION) {
fprintf(stderr, "in SEHHandler\n");
- fflush(stdout);
+ fflush(stderr);
TerminateProcess(GetCurrentProcess(), 0);
}
return EXCEPTION_CONTINUE_SEARCH;
@@ -29,6 +29,7 @@
int main() {
SetUnhandledExceptionFilter(SEHHandler);
fprintf(stderr, "in main\n");
+ fflush(stderr);
volatile int *p = nullptr;
*p = 42;