summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2013-04-12 00:43:57 +0200
committerLennart Poettering <lennart@poettering.net>2013-04-12 00:43:57 +0200
commit296f3c53cb4a87e297c019475f900fb3cca2d781 (patch)
treeddcedb1c395a9e81ae15c307e75e9272cda05a4f
parentb4da2689995b72fa32c3ba6555c6c3a3f6dce5e2 (diff)
bus: fix formatting of bus address
-rw-r--r--src/libsystemd-bus/test-bus-kernel.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/src/libsystemd-bus/test-bus-kernel.c b/src/libsystemd-bus/test-bus-kernel.c
index 143b9d54df..2241e65adf 100644
--- a/src/libsystemd-bus/test-bus-kernel.c
+++ b/src/libsystemd-bus/test-bus-kernel.c
@@ -36,7 +36,7 @@ int main(int argc, char *argv[]) {
bus_ref = bus_kernel_create("deine-mutter", &bus_name);
assert_se(bus_ref >= 0);
- address = strappend("kernel:", bus_name);
+ address = strappend("kernel:path=", bus_name);
assert_se(address);
r = sd_bus_new(&a);
@@ -60,12 +60,15 @@ int main(int argc, char *argv[]) {
r = sd_bus_get_unique_name(a, &ua);
assert_se(r >= 0);
- printf("unique a: %s", ua);
+ printf("unique a: %s\n", ua);
r = sd_bus_get_unique_name(b, &ub);
assert_se(r >= 0);
- printf("unique b: %s", ub);
+ printf("unique b: %s\n", ub);
+
+ sd_bus_unref(a);
+ sd_bus_unref(b);
return 0;
}