diff options
author | rwatson <rwatson@FreeBSD.org> | 2001-09-21 21:28:43 +0000 |
---|---|---|
committer | rwatson <rwatson@FreeBSD.org> | 2001-09-21 21:28:43 +0000 |
commit | d7c26820a74d15c452227019c1d5eeec4d1c14e5 (patch) | |
tree | 9665763ab71af83cd152368f0f93b5da810588df /tools/regression/security/access | |
parent | c9d707a81c70eb675cca02d0c565f6a2f9158ea3 (diff) | |
download | FreeBSD-src-d7c26820a74d15c452227019c1d5eeec4d1c14e5.zip FreeBSD-src-d7c26820a74d15c452227019c1d5eeec4d1c14e5.tar.gz |
o Fix two eaccess() checks -- in one case, the wrong test file
was used, resulting in a regression failure, and in the other,
the test on an error return was inverted.
Obtained from: TrustedBSD Project
Diffstat (limited to 'tools/regression/security/access')
-rw-r--r-- | tools/regression/security/access/testaccess.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/tools/regression/security/access/testaccess.c b/tools/regression/security/access/testaccess.c index bd6945e..7d0c843 100644 --- a/tools/regression/security/access/testaccess.c +++ b/tools/regression/security/access/testaccess.c @@ -223,7 +223,7 @@ main(int argc, char *argv[]) } #ifdef EACCESS_AVAILABLE - error = eaccess("test2", R_OK); + error = eaccess("test1", R_OK); if (!error) { fprintf(stderr, "saved uid used instead of effective uid\n"); errorseen++; @@ -270,7 +270,7 @@ main(int argc, char *argv[]) #ifdef EACCESS_AVAILABLE /* Check that the effective uid is used, not the real uid */ error = eaccess("test2", R_OK); - if (error) { + if (!error) { fprintf(stderr, "Real uid was used instead of effective uid in eaccess().\n"); errorseen++; } |