summaryrefslogtreecommitdiffstats
path: root/compiler-rt
diff options
context:
space:
mode:
authorVitaly Buka <vitalybuka@google.com>2018-06-16 04:01:08 +0000
committerVitaly Buka <vitalybuka@google.com>2018-06-16 04:01:08 +0000
commitb0a3e6f1271e448d121b85585017056758845c96 (patch)
tree9706f1c3f624b32755a8c62902a0f3fab283363b /compiler-rt
parent3b11794dbf5e11066739056390ba674d77a30e8e (diff)
downloadbcm5719-llvm-b0a3e6f1271e448d121b85585017056758845c96.tar.gz
bcm5719-llvm-b0a3e6f1271e448d121b85585017056758845c96.zip
[asan] Enable fgets_fputs test on Android
"echo data" didn't work because %run on android executes test on the device when lit shell command on the host system. https://github.com/google/sanitizers/issues/952 llvm-svn: 334883
Diffstat (limited to 'compiler-rt')
-rw-r--r--compiler-rt/test/asan/TestCases/Posix/fgets_fputs.cc7
1 files changed, 2 insertions, 5 deletions
diff --git a/compiler-rt/test/asan/TestCases/Posix/fgets_fputs.cc b/compiler-rt/test/asan/TestCases/Posix/fgets_fputs.cc
index 99828801778..34c952f2e02 100644
--- a/compiler-rt/test/asan/TestCases/Posix/fgets_fputs.cc
+++ b/compiler-rt/test/asan/TestCases/Posix/fgets_fputs.cc
@@ -1,9 +1,7 @@
// RUN: %clangxx_asan -g %s -o %t
-// RUN: echo data > %t-testdata
-// RUN: not %run %t 1 %t-testdata 2>&1 | FileCheck %s --check-prefix=CHECK-FGETS
+// RUN: not %run %t 1 2>&1 | FileCheck %s --check-prefix=CHECK-FGETS
// RUN: not %run %t 2 2>&1 | FileCheck %s --check-prefix=CHECK-FPUTS
// RUN: not %run %t 3 2>&1 | FileCheck %s --check-prefix=CHECK-PUTS
-// XFAIL: android
#include <assert.h>
#include <stdio.h>
@@ -39,8 +37,7 @@ int main(int argc, char *argv[]) {
assert(argc >= 2);
int testno = argv[1][0] - '0';
if (testno == 1) {
- assert(argc == 3);
- return test_fgets(argv[2]);
+ return test_fgets(argv[0]);
}
if (testno == 2)
return test_fputs();
OpenPOWER on IntegriCloud