diff --git a/compiler-rt/test/sanitizer_common/TestCases/Darwin/abort_on_error.cpp b/compiler-rt/test/sanitizer_common/TestCases/Darwin/abort_on_error.cpp --- a/compiler-rt/test/sanitizer_common/TestCases/Darwin/abort_on_error.cpp +++ b/compiler-rt/test/sanitizer_common/TestCases/Darwin/abort_on_error.cpp @@ -16,8 +16,8 @@ int main() { #if defined(USING_ubsan) - int value = 5; - int computation = value / 0; // Division by zero. + volatile int *null = 0; + *null = 0; #else volatile int *a = new int[100]; delete[] a;