summaryrefslogtreecommitdiff
path: root/src/up-kbd-backlight.c
diff options
context:
space:
mode:
authorMartin Pitt <martin.pitt@ubuntu.com>2011-04-20 00:43:59 +0200
committerMartin Pitt <martin.pitt@ubuntu.com>2011-04-26 11:50:36 +0200
commiteddcf0ef3d0b8445618e368328d7e110a83b69b3 (patch)
tree937533db5a23c50d32b8b6d46d2f493557ed310a /src/up-kbd-backlight.c
parentf65aa4dbf2721a660300d14fc3a582d3be3c3072 (diff)
Add option to run daemon on the session bus for testing
Add a daemon option --test which will run upowerd on the session bus. This allows us to run tests without interfering with the system instance. This also avoids any root privileges entirely, which permits running integration tests as part of a package build.
Diffstat (limited to 'src/up-kbd-backlight.c')
-rw-r--r--src/up-kbd-backlight.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/up-kbd-backlight.c b/src/up-kbd-backlight.c
index fc34cd7..2be22b6 100644
--- a/src/up-kbd-backlight.c
+++ b/src/up-kbd-backlight.c
@@ -273,7 +273,7 @@ up_kbd_backlight_init (UpKbdBacklight *kbd_backlight)
return;
}
- kbd_backlight->priv->connection = dbus_g_bus_get (DBUS_BUS_SYSTEM, &error);
+ kbd_backlight->priv->connection = dbus_g_bus_get (up_daemon_get_bus_type (), &error);
if (error != NULL) {
g_warning ("Cannot connect to bus: %s", error->message);
g_error_free (error);