aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorTed Gould <ted@gould.cx>2011-03-11 15:49:21 -0600
committerTed Gould <ted@gould.cx>2011-03-11 15:49:21 -0600
commitc892f84845aeb7367c9246a679a21da09ebafd2c (patch)
tree3e9403e32742de0a3bcd226e903e06aa43976585 /src
parentbc6a7d9b4fd1dd9edc477edfdba39a34069ec53d (diff)
downloadayatana-indicator-application-c892f84845aeb7367c9246a679a21da09ebafd2c.tar.gz
ayatana-indicator-application-c892f84845aeb7367c9246a679a21da09ebafd2c.tar.bz2
ayatana-indicator-application-c892f84845aeb7367c9246a679a21da09ebafd2c.zip
Only clear the cancel if we're not being cancelled
Diffstat (limited to 'src')
-rw-r--r--src/indicator-application.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/src/indicator-application.c b/src/indicator-application.c
index c2dd16a..f9b200b 100644
--- a/src/indicator-application.c
+++ b/src/indicator-application.c
@@ -823,14 +823,16 @@ get_applications (GObject * obj, GAsyncResult * res, gpointer user_data)
GVariant * child;
GVariantIter * iter;
+ result = g_dbus_proxy_call_finish(priv->service_proxy, res, &error);
+
/* No one can cancel us anymore, we've completed! */
if (priv->get_apps_cancel != NULL) {
- g_object_unref(priv->get_apps_cancel);
- priv->get_apps_cancel = NULL;
+ if (error == NULL || error->domain != G_IO_ERROR || error->code != G_IO_ERROR_CANCELLED) {
+ g_object_unref(priv->get_apps_cancel);
+ priv->get_apps_cancel = NULL;
+ }
}
- result = g_dbus_proxy_call_finish(priv->service_proxy, res, &error);
-
if (error != NULL) {
g_warning("Unable to get application list: %s", error->message);
return;