projects
/
platform
/
upstream
/
systemd.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
d09a258
)
capability: minor coding style updates
author
Lennart Poettering
<lennart@poettering.net>
Thu, 21 Mar 2019 11:30:49 +0000
(12:30 +0100)
committer
Lennart Poettering
<lennart@poettering.net>
Thu, 21 Mar 2019 11:30:49 +0000
(12:30 +0100)
src/basic/capability-util.c
patch
|
blob
|
history
diff --git
a/src/basic/capability-util.c
b/src/basic/capability-util.c
index
aca861e
..
9f66027
100644
(file)
--- a/
src/basic/capability-util.c
+++ b/
src/basic/capability-util.c
@@
-28,8
+28,8
@@
int have_effective_cap(int value) {
if (cap_get_flag(cap, value, CAP_EFFECTIVE, &fv) < 0)
return -errno;
- else
-
return fv == CAP_SET;
+
+ return fv == CAP_SET;
}
unsigned long cap_last_cap(void) {
@@
-107,13
+107,13
@@
int capability_update_inherited_set(cap_t caps, uint64_t set) {
}
int capability_ambient_set_apply(uint64_t set, bool also_inherit) {
- unsigned long i;
_cleanup_cap_free_ cap_t caps = NULL;
+ unsigned long i;
+ int r;
/* Add the capabilities to the ambient set. */
if (also_inherit) {
- int r;
caps = cap_get_proc();
if (!caps)
return -errno;