Skip to contentSkip to conversation

syscalls/getxattr05: Exit with TCONF when ACL is not supported

PATCH New Cyril Hrubis 1 participant 1 message Oct 4, 2018

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 syscalls/getxattr05: Exit with TCONF when ACL is not supported

---
 testcases/kernel/syscalls/getxattr/getxattr05.c | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)
testcases/kernel/syscalls/getxattr/getxattr05.c +5 -1
index 8656205f2..31b985ee0 100644
@@ -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().
Signature · 1 line
2.16.4