diff --git a/lib/packagekit-glib2/pk-client.c b/lib/packagekit-glib2/pk-client.c index 0a2db1fea..bfb7e534c 100644 --- a/lib/packagekit-glib2/pk-client.c +++ b/lib/packagekit-glib2/pk-client.c @@ -194,6 +194,8 @@ pk_client_state_unset_proxy (PkClientState *state) state); g_clear_object (&state->proxy); } + + g_object_unref (state); } static void @@ -1657,6 +1659,8 @@ pk_client_proxy_connect (PkClientState *state) guint i; g_auto(GStrv) props = NULL; + g_object_ref (state); + /* coldplug properties */ props = g_dbus_proxy_get_cached_property_names (state->proxy); for (i = 0; props != NULL && props[i] != NULL; i++) {