Skip to content

Commit 404ca22

Browse files
authored
Replace |& with 2>&1 in ignore_free_hooks test. (#100004)
The test file ignore_free_hooks.cpp (added in https://github.com/llvm/llvm-project/pull/96749/files) fails on mac because `|&` doesn't work on mac. Replace with `2>&1`.
1 parent f0fad9f commit 404ca22

File tree

2 files changed

+10
-10
lines changed

2 files changed

+10
-10
lines changed

compiler-rt/test/asan/TestCases/Posix/ignore_free_hook.cpp

+6-6
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,15 @@
11
// RUN: %clangxx_asan -O2 %s -o %t -DTEST=basic_hook_works && not %run %t \
2-
// RUN: |& FileCheck %s -check-prefix=CHECK-BASIC
2+
// RUN: 2>&1 | FileCheck %s -check-prefix=CHECK-BASIC
33
// RUN: %clangxx_asan -O2 %s -o %t -DTEST=ignore && %run %t \
4-
// RUN: |& FileCheck %s -check-prefix=CHECK-IGNORE
4+
// RUN: 2>&1 | FileCheck %s -check-prefix=CHECK-IGNORE
55
// RUN: %clangxx_asan -O2 %s -o %t -DTEST=ignore_twice && not %run %t \
6-
// RUN: |& FileCheck %s -check-prefix=CHECK-IGNORE-2
6+
// RUN: 2>&1 | FileCheck %s -check-prefix=CHECK-IGNORE-2
77
// RUN: %clangxx_asan -O2 %s -o %t -DTEST=mismatch && %env_asan_opts=alloc_dealloc_mismatch=1 not %run %t \
8-
// RUN: |& FileCheck %s -check-prefix=CHECK-MISMATCH
8+
// RUN: 2>&1 | FileCheck %s -check-prefix=CHECK-MISMATCH
99
// RUN: %clangxx_asan -O2 %s -o %t -DTEST=ignore_mismatch && %env_asan_opts=alloc_dealloc_mismatch=1 %run %t \
10-
// RUN: |& FileCheck %s -check-prefix=CHECK-IGNORE-MISMATCH
10+
// RUN: 2>&1 | FileCheck %s -check-prefix=CHECK-IGNORE-MISMATCH
1111
// RUN: %clangxx_asan -O2 %s -o %t -DTEST=double_delete && not %run %t \
12-
// RUN: |& FileCheck %s -check-prefix=CHECK-DOUBLE-DELETE
12+
// RUN: 2>&1 | FileCheck %s -check-prefix=CHECK-DOUBLE-DELETE
1313

1414
#include <stdio.h>
1515
#include <stdlib.h>

compiler-rt/test/hwasan/TestCases/Posix/ignore_free_hook.cpp

+4-4
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
// RUN: %clangxx_hwasan -O2 %s -o %t -DTEST=basic_hook_works && not %run %t \
2-
// RUN: |& FileCheck %s -check-prefix=CHECK-BASIC
2+
// RUN: 2>&1 | FileCheck %s -check-prefix=CHECK-BASIC
33
// RUN: %clangxx_hwasan -O2 %s -o %t -DTEST=ignore && %run %t \
4-
// RUN: |& FileCheck %s -check-prefix=CHECK-IGNORE
4+
// RUN: 2>&1 | FileCheck %s -check-prefix=CHECK-IGNORE
55
// RUN: %clangxx_hwasan -O2 %s -o %t -DTEST=ignore_twice && not %run %t \
6-
// RUN: |& FileCheck %s -check-prefix=CHECK-IGNORE-2
6+
// RUN: 2>&1 | FileCheck %s -check-prefix=CHECK-IGNORE-2
77
// RUN: %clangxx_hwasan -O2 %s -o %t -DTEST=double_delete && not %run %t \
8-
// RUN: |& FileCheck %s -check-prefix=CHECK-DOUBLE-DELETE
8+
// RUN: 2>&1 | FileCheck %s -check-prefix=CHECK-DOUBLE-DELETE
99

1010
#include <sanitizer/hwasan_interface.h>
1111
#include <stdio.h>

0 commit comments

Comments
 (0)