Skip to content

Commit 0c1a374

Browse files
fix
1 parent 0c2ba3d commit 0c1a374

File tree

1 file changed

+12
-6
lines changed

1 file changed

+12
-6
lines changed

compiler-rt/test/asan/TestCases/Linux/allocator_oom_test.cpp

Lines changed: 12 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -11,17 +11,23 @@
1111
// RUN: ulimit -v 22024290304
1212
// RUN: not %run %t malloc 2>&1 \
1313
// RUN: | FileCheck %s --check-prefixes=CHECK-MALLOC,CHECK-CRASH
14-
// RUN: %env_asan_opts=allocator_may_return_null=0 not %run %t malloc 2>&1 \
14+
// RUN: %export_asan_opts=allocator_may_return_null=0
15+
// RUN: not %run %t malloc 2>&1 \
1516
// RUN: | FileCheck %s --check-prefixes=CHECK-MALLOC,CHECK-CRASH
16-
// RUN: %env_asan_opts=allocator_may_return_null=1 %run %t malloc 2>&1 \
17+
// RUN: %export_asan_opts=allocator_may_return_null=1
18+
// RUN: %run %t malloc 2>&1 \
1719
// RUN: | FileCheck %s --check-prefixes=CHECK-MALLOC,CHECK-NULL
18-
// RUN: %env_asan_opts=allocator_may_return_null=0 not %run %t calloc 2>&1 \
20+
// RUN: %export_asan_opts=allocator_may_return_null=0
21+
// RUN: not %run %t calloc 2>&1 \
1922
// RUN: | FileCheck %s --check-prefixes=CHECK-CALLOC,CHECK-CRASH
20-
// RUN: %env_asan_opts=allocator_may_return_null=1 %run %t calloc 2>&1 \
23+
// RUN: %export_asan_opts=allocator_may_return_null=1
24+
// RUN: %run %t calloc 2>&1 \
2125
// RUN: | FileCheck %s --check-prefixes=CHECK-CALLOC,CHECK-NULL
22-
// RUN: %env_asan_opts=allocator_may_return_null=0 not %run %t realloc 2>&1 \
26+
// RUN: %export_asan_opts=allocator_may_return_null=0
27+
// RUN: not %run %t realloc 2>&1 \
2328
// RUN: | FileCheck %s --check-prefixes=CHECK-REALLOC,CHECK-CRASH
24-
// RUN: %env_asan_opts=allocator_may_return_null=1 %run %t realloc 2>&1 \
29+
// RUN: %export_asan_opts=allocator_may_return_null=1
30+
// RUN: %run %t realloc 2>&1 \
2531
// RUN: | FileCheck %s --check-prefixes=CHECK-REALLOC,CHECK-NULL
2632
// RUN: %export_asan_opts=allocator_may_return_null=0
2733
// RUN: not %run %t realloc-after-malloc 2>&1 \

0 commit comments

Comments
 (0)