From 913c898ca01f4ad90a38684505f88b7d0e6724fd Mon Sep 17 00:00:00 2001 From: Lennart Poettering Date: Fri, 12 Oct 2018 18:32:22 +0200 Subject: [PATCH] cgroup: voidify a few things --- src/core/cgroup.c | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/src/core/cgroup.c b/src/core/cgroup.c index ff5f1d5171..c89f57a67f 100644 --- a/src/core/cgroup.c +++ b/src/core/cgroup.c @@ -500,9 +500,9 @@ static int whitelist_major(BPFProgram *prog, const char *path, const char *name, if (!prog) continue; - cgroup_bpf_whitelist_major(prog, - type == 'c' ? BPF_DEVCG_DEV_CHAR : BPF_DEVCG_DEV_BLOCK, - maj, acc); + (void) cgroup_bpf_whitelist_major(prog, + type == 'c' ? BPF_DEVCG_DEV_CHAR : BPF_DEVCG_DEV_BLOCK, + maj, acc); } else { char buf[2+DECIMAL_STR_MAX(unsigned)+3+4]; @@ -1080,10 +1080,10 @@ static void cgroup_context_apply( const char *x, *y; NULSTR_FOREACH_PAIR(x, y, auto_devices) - whitelist_device(prog, path, x, y); + (void) whitelist_device(prog, path, x, y); /* PTS (/dev/pts) devices may not be duplicated, but accessed */ - whitelist_major(prog, path, "pts", 'c', "rw"); + (void) whitelist_major(prog, path, "pts", 'c', "rw"); } LIST_FOREACH(device_allow, a, c->device_allow) { @@ -1103,11 +1103,11 @@ static void cgroup_context_apply( acc[k++] = 0; if (path_startswith(a->path, "/dev/")) - whitelist_device(prog, path, a->path, acc); + (void) whitelist_device(prog, path, a->path, acc); else if ((val = startswith(a->path, "block-"))) - whitelist_major(prog, path, val, 'b', acc); + (void) whitelist_major(prog, path, val, 'b', acc); else if ((val = startswith(a->path, "char-"))) - whitelist_major(prog, path, val, 'c', acc); + (void) whitelist_major(prog, path, val, 'c', acc); else log_unit_debug(u, "Ignoring device %s while writing cgroup attribute.", a->path); }