diff options
Diffstat (limited to 'lib/asan/lit_tests/TestCases/assign_large_valloc_to_global.cc')
-rw-r--r-- | lib/asan/lit_tests/TestCases/assign_large_valloc_to_global.cc | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/lib/asan/lit_tests/TestCases/assign_large_valloc_to_global.cc b/lib/asan/lit_tests/TestCases/assign_large_valloc_to_global.cc new file mode 100644 index 000000000000..b0a501576945 --- /dev/null +++ b/lib/asan/lit_tests/TestCases/assign_large_valloc_to_global.cc @@ -0,0 +1,8 @@ +// Make sure we don't report a leak nor hang. +// RUN: %clangxx_asan -O3 %s -o %t && %t +#include <stdlib.h> +#ifndef __APPLE__ +#include <malloc.h> +#endif // __APPLE__ +int *p = (int*)valloc(1 << 20); +int main() { } |