summaryrefslogtreecommitdiff
path: root/io
diff options
context:
space:
mode:
Diffstat (limited to 'io')
-rw-r--r--io/tst-faccessat.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/io/tst-faccessat.c b/io/tst-faccessat.c
index 3bf7aed2e5..52b2e7b752 100644
--- a/io/tst-faccessat.c
+++ b/io/tst-faccessat.c
@@ -135,7 +135,7 @@ do_test (void)
errno = 0;
if (faccessat (dir_fd, "some-file", W_OK, AT_EACCESS) == 0
- || errno != EACCES)
+ ? (geteuid () != 0) : (errno != EACCES))
{
printf ("faccessat W_OK on unwritable file: %m\n");
result = 1;