diff options
author | Mike Frysinger <vapier@gentoo.org> | 2015-12-20 16:32:26 -0500 |
---|---|---|
committer | Mike Frysinger <vapier@gentoo.org> | 2015-12-20 16:32:26 -0500 |
commit | 4f000d9c228474b6e34c9ce9e84bcce781271914 (patch) | |
tree | 277ebaa1e092f20ebf43616c322cd37cebef4f1b /tests | |
parent | libsbutil: gnulib: hand disable same_name usage (diff) | |
download | sandbox-4f000d9c228474b6e34c9ce9e84bcce781271914.tar.gz sandbox-4f000d9c228474b6e34c9ce9e84bcce781271914.tar.bz2 sandbox-4f000d9c228474b6e34c9ce9e84bcce781271914.zip |
tests: check errno with more static tests
This verifies the error code setting with ptrace logic -- if the ptrace
code is broken, the errno will often be ENOSYS instead of EPERM.
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
Diffstat (limited to 'tests')
-rwxr-xr-x | tests/open_static-1.sh | 2 | ||||
-rwxr-xr-x | tests/openat_static-1.sh | 2 | ||||
-rwxr-xr-x | tests/unlink_static-1.sh | 2 |
3 files changed, 3 insertions, 3 deletions
diff --git a/tests/open_static-1.sh b/tests/open_static-1.sh index faf91d0..e815b57 100755 --- a/tests/open_static-1.sh +++ b/tests/open_static-1.sh @@ -8,5 +8,5 @@ open_static-0 3 ok O_RDONLY 0666 || exit 1 mkdir deny || exit 1 adddeny $PWD/deny -open_static-0 -1 deny/not-ok "O_WRONLY|O_CREAT" 0666 +open_static-0 -1,EPERM deny/not-ok "O_WRONLY|O_CREAT" 0666 || exit 1 test -e sandbox.log diff --git a/tests/openat_static-1.sh b/tests/openat_static-1.sh index 929fc51..a4d1b90 100755 --- a/tests/openat_static-1.sh +++ b/tests/openat_static-1.sh @@ -8,5 +8,5 @@ openat_static-0 3 AT_FDCWD ok O_RDONLY 0666 || exit 1 mkdir deny || exit 1 adddeny $PWD/deny -openat_static-0 -1 AT_FDCWD deny/not-ok "O_WRONLY|O_CREAT" 0666 +openat_static-0 -1,EPERM AT_FDCWD deny/not-ok "O_WRONLY|O_CREAT" 0666 || exit 1 test -e sandbox.log diff --git a/tests/unlink_static-1.sh b/tests/unlink_static-1.sh index 9585862..2281a98 100755 --- a/tests/unlink_static-1.sh +++ b/tests/unlink_static-1.sh @@ -5,5 +5,5 @@ touch f test -e f || exit 1 adddeny "${PWD}" -unlink_static-0 -1,EPERM f +unlink_static-0 -1,EPERM f || exit 1 test -e sandbox.log -a -e f |