summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2010-07-11 23:01:42 +0200
committerLennart Poettering <lennart@poettering.net>2010-07-11 23:02:46 +0200
commitc2ad51299afe046f3a65b4f57bcbd38b2cce2234 (patch)
tree76e7bfa3e1a93736f9155f46c2e81b231ef3a3dd
parentb5f776cee9afc14e6c4b945be0576ab3b27e33b7 (diff)
install: fix wrong dbus connection shutdown
-rw-r--r--src/install.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/src/install.c b/src/install.c
index 2c57c9b60..38c0513fa 100644
--- a/src/install.c
+++ b/src/install.c
@@ -773,7 +773,7 @@ static char *get_config_path(void) {
}
}
-static int do_run(void) {
+static int do_realize(void) {
DBusConnection *bus = NULL;
DBusError error;
int r, q;
@@ -827,8 +827,10 @@ static int do_run(void) {
r = q;
finish:
- if (bus)
+ if (bus) {
+ dbus_connection_close(bus);
dbus_connection_unref(bus);
+ }
dbus_error_free(&error);
@@ -889,7 +891,7 @@ int main(int argc, char *argv[]) {
}
}
- if (do_run() < 0)
+ if (do_realize() < 0)
goto finish;
retval = arg_action == ACTION_TEST ? 1 : 0;