Thread (3 messages) flat view 3 messages, 2 authors, 2015-06-17
STALE4087d

[PATCH] selftests/kdbus: handle cap_get_proc() error properly

From: Sergei Zviagintsev <hidden>
Date: 2015-06-17 14:19:36
Also in: lkml
Subsystem: kernel selftest framework, the rest · Maintainers: Shuah Khan, Shuah Khan, Linus Torvalds

Fix typo in checking error value of cap_get_proc(): cap -> caps

Signed-off-by: Sergei Zviagintsev <redacted>
---
 tools/testing/selftests/kdbus/kdbus-util.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/tools/testing/selftests/kdbus/kdbus-util.c b/tools/testing/selftests/kdbus/kdbus-util.c
index 1e267d585a14..a3e49b04f3a7 100644
--- a/tools/testing/selftests/kdbus/kdbus-util.c
+++ b/tools/testing/selftests/kdbus/kdbus-util.c
@@ -1547,7 +1547,7 @@ int test_is_capable(int cap, ...)
 	cap_t caps;
 
 	caps = cap_get_proc();
-	if (!cap) {
+	if (!caps) {
 		ret = -errno;
 		kdbus_printf("error cap_get_proc(): %d (%m)\n", ret);
 		return ret;
-- 
1.8.3.1
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help