aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/datetime-prefs.c9
-rw-r--r--src/service.c12
2 files changed, 15 insertions, 6 deletions
diff --git a/src/datetime-prefs.c b/src/datetime-prefs.c
index ef0a553..1eaaf1e 100644
--- a/src/datetime-prefs.c
+++ b/src/datetime-prefs.c
@@ -176,7 +176,8 @@ polkit_perm_ready (GObject *source_object, GAsyncResult *res, gpointer user_data
GPermission * permission = polkit_permission_new_finish (res, &error);
if (error != NULL) {
- g_warning ("Could not get permission object: %s", error->message);
+ if (!g_error_matches (error, G_IO_ERROR, G_IO_ERROR_CANCELLED))
+ g_warning ("Could not get permission object: %s", error->message);
g_error_free (error);
return;
}
@@ -192,7 +193,8 @@ dbus_set_answered (GObject *object, GAsyncResult *res, gpointer command)
GVariant * answers = g_dbus_proxy_call_finish (G_DBUS_PROXY (object), res, &error);
if (error != NULL) {
- g_warning("Could not set '%s' using timedated: %s", (gchar *)command, error->message);
+ if (!g_error_matches (error, G_IO_ERROR, G_IO_ERROR_CANCELLED))
+ g_warning("Could not set '%s' using timedated: %s", (gchar *)command, error->message);
g_error_free(error);
return;
}
@@ -247,7 +249,8 @@ proxy_ready (GObject *object, GAsyncResult *res, IndicatorDatetimePanel * self)
self->priv->proxy = g_dbus_proxy_new_for_bus_finish (res, &error);
if (error != NULL) {
- g_critical("Could not grab DBus proxy for timedated: %s", error->message);
+ if (!g_error_matches (error, G_IO_ERROR, G_IO_ERROR_CANCELLED))
+ g_critical("Could not grab DBus proxy for timedated: %s", error->message);
g_error_free(error);
return;
}
diff --git a/src/service.c b/src/service.c
index 5c8f966..5694ffe 100644
--- a/src/service.c
+++ b/src/service.c
@@ -1036,7 +1036,9 @@ on_datetime1_set_timezone_response (GObject * object,
answers = g_dbus_proxy_call_finish (G_DBUS_PROXY(object), res, &err);
if (err != NULL)
{
- g_warning ("Could not set new timezone: %s", err->message);
+ if (!g_error_matches (err, G_IO_ERROR, G_IO_ERROR_CANCELLED))
+ g_warning ("Could not set new timezone: %s", err->message);
+
g_error_free (err);
}
else
@@ -1069,7 +1071,9 @@ on_datetime1_proxy_ready (GObject * object G_GNUC_UNUSED,
proxy = g_dbus_proxy_new_for_bus_finish (res, &err);
if (err != NULL)
{
- g_warning ("Could not grab DBus proxy for timedated: %s", err->message);
+ if (!g_error_matches (err, G_IO_ERROR, G_IO_ERROR_CANCELLED))
+ g_warning ("Could not grab DBus proxy for timedated: %s", err->message);
+
g_error_free (err);
setlocation_data_free (data);
}
@@ -1422,7 +1426,9 @@ on_login1_manager_proxy_ready (GObject * object G_GNUC_UNUSED,
if (err != NULL)
{
- g_warning ("Could not grab DBus proxy for logind: %s", err->message);
+ if (!g_error_matches (err, G_IO_ERROR, G_IO_ERROR_CANCELLED))
+ g_warning ("Could not grab DBus proxy for logind: %s", err->message);
+
g_error_free (err);
}
else