Skip to content

Commit d2c5e49

Browse files
[NSan] Make Tests work with Internal Shell
There was one test that was using a subshell. This is not supported by lit's internal shell. Rewrite the test to use the readfile substitution. Reviewers: alexander-shaposhnikov, fmayer Reviewed By: alexander-shaposhnikov, fmayer Pull Request: #165142
1 parent 8067b5c commit d2c5e49

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

compiler-rt/test/nsan/Posix/allocator_mapping.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,8 @@
22
/// Test that a module constructor can not map memory over the NSan heap
33
/// (without MAP_FIXED, of course).
44
// RUN: %clangxx_nsan -O0 %s -o %t_1
5-
// RUN: %clangxx_nsan -O0 -DHEAP_ADDRESS=$(%run %t_1) %s -o %t_2 && %run %t_2
5+
// RUN: %run %t_1 > %t.heap_address
6+
// RUN: %clangxx_nsan -O0 -DHEAP_ADDRESS=%{readfile:%t.heap_address} %s -o %t_2 && %run %t_2
67

78
#include <assert.h>
89
#include <stdio.h>

0 commit comments

Comments
 (0)