[LTP] [PATCH] [COMMITTED] syscalls/getxattr05: Exit with TCONF when ACL is not supported
Cyril Hrubis
chrubis@suse.cz
Thu Oct 4 16:33:12 CEST 2018
Signed-off-by: Cyril Hrubis <chrubis@suse.cz>
---
testcases/kernel/syscalls/getxattr/getxattr05.c | 6 +++++-
1 file changed, 5 insertions(+), 1 deletion(-)
diff --git a/testcases/kernel/syscalls/getxattr/getxattr05.c b/testcases/kernel/syscalls/getxattr/getxattr05.c
index 8656205f2..31b985ee0 100644
--- a/testcases/kernel/syscalls/getxattr/getxattr05.c
+++ b/testcases/kernel/syscalls/getxattr/getxattr05.c
@@ -134,8 +134,12 @@ static void setup(void)
tst_brk(TBROK | TERRNO, "acl_from_text() failed");
res = acl_set_file(TEST_FILE, ACL_TYPE_ACCESS, acl);
- if (res == -1)
+ if (res == -1) {
+ if (errno == EOPNOTSUPP)
+ tst_brk(TCONF | TERRNO, "acl_set_file()");
+
tst_brk(TBROK | TERRNO, "acl_set_file(%s) failed", TEST_FILE);
+ }
/* The default value of max_user_namespaces is set to 0 on some distros,
* We need to change the default value to call unshare().
--
2.16.4
More information about the ltp
mailing list