summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2014-10-27 13:06:11 +0100
committerLennart Poettering <lennart@poettering.net>2014-10-27 13:06:20 +0100
commit24f6fc22c10fe4fbb3c24fd90ff09085dc402bbf (patch)
treebb9330a45415f632c84f8fb39f0999d6b7a21ff9
parent54ad51e3e92c92240205aab2f9479c041cdaaf8f (diff)
sd-bus: explicitly cast asprintf() return value away we are not interested in
Let's give coverity a hint what's going on here.
-rw-r--r--src/libsystemd/sd-bus/sd-bus.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/libsystemd/sd-bus/sd-bus.c b/src/libsystemd/sd-bus/sd-bus.c
index c2931a7f7b..03ec6036fa 100644
--- a/src/libsystemd/sd-bus/sd-bus.c
+++ b/src/libsystemd/sd-bus/sd-bus.c
@@ -1157,13 +1157,13 @@ int bus_set_address_user(sd_bus *b) {
return -ENOMEM;
#ifdef ENABLE_KDBUS
- asprintf(&b->address, KERNEL_USER_BUS_FMT ";" UNIX_USER_BUS_FMT, getuid(), ee);
+ (void) asprintf(&b->address, KERNEL_USER_BUS_FMT ";" UNIX_USER_BUS_FMT, getuid(), ee);
#else
- asprintf(&b->address, UNIX_USER_BUS_FMT, ee);
+ (void) asprintf(&b->address, UNIX_USER_BUS_FMT, ee);
#endif
} else {
#ifdef ENABLE_KDBUS
- asprintf(&b->address, KERNEL_USER_BUS_FMT, getuid());
+ (void) asprintf(&b->address, KERNEL_USER_BUS_FMT, getuid());
#else
return -ECONNREFUSED;
#endif