summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2013-04-12 00:43:12 +0200
committerLennart Poettering <lennart@poettering.net>2013-04-12 00:43:12 +0200
commitde2975759deb218144ed949fb42eccb33b752826 (patch)
tree58b6aee359fdca98d9e742c2c31bd2ad284ff9f3 /src
parentdd418b9a69cdfc7c186d86d03b34d83577b0c319 (diff)
bus: fill in unique name when using kdbus
Diffstat (limited to 'src')
-rw-r--r--src/libsystemd-bus/bus-kernel.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/libsystemd-bus/bus-kernel.c b/src/libsystemd-bus/bus-kernel.c
index c10fcc54df..65b8b7b961 100644
--- a/src/libsystemd-bus/bus-kernel.c
+++ b/src/libsystemd-bus/bus-kernel.c
@@ -156,6 +156,9 @@ int bus_kernel_take_fd(sd_bus *b) {
if (r < 0)
return -errno;
+ if (asprintf(&b->unique_name, ":1.%llu", (unsigned long long) hello.id) < 0)
+ return -ENOMEM;
+
b->is_kernel = true;
r = bus_start_running(b);