summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--compiler-rt/test/sanitizer_common/TestCases/Posix/access.cc2
-rw-r--r--compiler-rt/test/sanitizer_common/TestCases/Posix/devname_r.cc4
2 files changed, 3 insertions, 3 deletions
diff --git a/compiler-rt/test/sanitizer_common/TestCases/Posix/access.cc b/compiler-rt/test/sanitizer_common/TestCases/Posix/access.cc
index 92c2a9fd847..8623645f8bd 100644
--- a/compiler-rt/test/sanitizer_common/TestCases/Posix/access.cc
+++ b/compiler-rt/test/sanitizer_common/TestCases/Posix/access.cc
@@ -2,4 +2,4 @@
#include <unistd.h>
-int main(void) { return access("/root", F_OK); }
+int main(void) { return access("/dev/null", F_OK); }
diff --git a/compiler-rt/test/sanitizer_common/TestCases/Posix/devname_r.cc b/compiler-rt/test/sanitizer_common/TestCases/Posix/devname_r.cc
index f7925f55597..826b7c92ef2 100644
--- a/compiler-rt/test/sanitizer_common/TestCases/Posix/devname_r.cc
+++ b/compiler-rt/test/sanitizer_common/TestCases/Posix/devname_r.cc
@@ -9,7 +9,7 @@
int main(void) {
struct stat st;
- char name[10];
+ char name[100];
mode_t type;
if (stat("/dev/null", &st))
@@ -17,7 +17,7 @@ int main(void) {
type = S_ISCHR(st.st_mode) ? S_IFCHR : S_IFBLK;
- if (devname_r(st.st_rdev, type, name, sizeof(name)))
+ if (!devname_r(st.st_rdev, type, name, sizeof(name)))
exit(1);
printf("%s\n", name);
OpenPOWER on IntegriCloud