From 2492e340aa039e19f2e937bab3d9ab3c930de8da Mon Sep 17 00:00:00 2001 From: Daniel Mack Date: Thu, 27 Feb 2014 19:10:40 +0100 Subject: bus: document kdbus_bus_uid_is_privileged() --- bus.c | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'bus.c') diff --git a/bus.c b/bus.c index 25dd375705f..cc3f1e49d32 100644 --- a/bus.c +++ b/bus.c @@ -28,6 +28,15 @@ #include "names.h" #include "domain.h" +/** + * kdbus_bus_uid_is_privileged() - check whether the current user is a + * priviledged bus user + * @bus: The bus to check + * + * Return: true if the current user has CAP_IPC_OWNER capabilities, or + * if it has the same UID as the user that created the bus. Otherwise, + * false is returned. + */ bool kdbus_bus_uid_is_privileged(const struct kdbus_bus *bus) { if (capable(CAP_IPC_OWNER)) -- cgit v1.2.3