summaryrefslogtreecommitdiff
path: root/test/tsan/fd_close_norace2.cc
diff options
context:
space:
mode:
authorRenato Golin <renato.golin@linaro.org>2016-03-02 11:10:02 +0000
committerRenato Golin <renato.golin@linaro.org>2016-03-02 11:10:02 +0000
commitf4faa6e4febbc20e71d0a625020b4f1c3237070e (patch)
tree4a12bab5aa596b09e8057032ae5913c5b74344c2 /test/tsan/fd_close_norace2.cc
parent7fff5d88a3f43e24f54910cbb2a2c701113d6178 (diff)
[RT] Make tsan tests more portable
by avoiding potential races when scanning stdout and stderr output. Patch by Maxim Kuvyrkov. git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@262476 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/tsan/fd_close_norace2.cc')
-rw-r--r--test/tsan/fd_close_norace2.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/test/tsan/fd_close_norace2.cc b/test/tsan/fd_close_norace2.cc
index bf94fd551..382ae5f34 100644
--- a/test/tsan/fd_close_norace2.cc
+++ b/test/tsan/fd_close_norace2.cc
@@ -23,7 +23,7 @@ int main() {
while (write(pipes[1], &t, 1) != 1) {
}
pthread_join(t, 0);
- printf("OK\n");
+ fprintf(stderr, "OK\n");
}
// CHECK-NOT: WARNING: ThreadSanitizer: data race