aboutsummaryrefslogtreecommitdiffstats
path: root/e-util/e-name-selector.c
diff options
context:
space:
mode:
authorMatthew Barnes <mbarnes@redhat.com>2013-09-08 00:31:19 +0800
committerMatthew Barnes <mbarnes@redhat.com>2013-09-08 07:08:54 +0800
commit3da4948c0fc1f2c21b163f0ec456b2d99c881258 (patch)
tree479d6153d31e03cb7a65990683b5271402e5ec29 /e-util/e-name-selector.c
parent2e5031cb4538b4819e5fce5d717668c3445df80a (diff)
downloadgsoc2013-evolution-3da4948c0fc1f2c21b163f0ec456b2d99c881258.tar
gsoc2013-evolution-3da4948c0fc1f2c21b163f0ec456b2d99c881258.tar.gz
gsoc2013-evolution-3da4948c0fc1f2c21b163f0ec456b2d99c881258.tar.bz2
gsoc2013-evolution-3da4948c0fc1f2c21b163f0ec456b2d99c881258.tar.lz
gsoc2013-evolution-3da4948c0fc1f2c21b163f0ec456b2d99c881258.tar.xz
gsoc2013-evolution-3da4948c0fc1f2c21b163f0ec456b2d99c881258.tar.zst
gsoc2013-evolution-3da4948c0fc1f2c21b163f0ec456b2d99c881258.zip
Miscellaneous cleanups.
Diffstat (limited to 'e-util/e-name-selector.c')
-rw-r--r--e-util/e-name-selector.c16
1 files changed, 12 insertions, 4 deletions
diff --git a/e-util/e-name-selector.c b/e-util/e-name-selector.c
index 9f2f48cea8..3c5340c37c 100644
--- a/e-util/e-name-selector.c
+++ b/e-util/e-name-selector.c
@@ -100,6 +100,7 @@ name_selector_get_client_cb (GObject *source_object,
GArray *sections;
SourceBook source_book;
guint ii;
+ gboolean ignore_error;
GError *error = NULL;
client = e_client_cache_get_client_finish (
@@ -110,11 +111,18 @@ name_selector_get_client_cb (GObject *source_object,
((client != NULL) && (error == NULL)) ||
((client == NULL) && (error != NULL)));
+ ignore_error =
+ g_error_matches (
+ error, E_CLIENT_ERROR,
+ E_CLIENT_ERROR_REPOSITORY_OFFLINE) ||
+ g_error_matches (
+ error, E_CLIENT_ERROR,
+ E_CLIENT_ERROR_OFFLINE_UNAVAILABLE) ||
+ g_error_matches (
+ error, G_IO_ERROR, G_IO_ERROR_CANCELLED);
+
if (error != NULL) {
- if (!g_error_matches (error, E_CLIENT_ERROR, E_CLIENT_ERROR_REPOSITORY_OFFLINE)
- && !g_error_matches (error, E_CLIENT_ERROR, E_CLIENT_ERROR_OFFLINE_UNAVAILABLE)
- && !g_error_matches (error, E_CLIENT_ERROR, E_CLIENT_ERROR_CANCELLED)
- && !g_error_matches (error, G_IO_ERROR, G_IO_ERROR_CANCELLED))
+ if (!ignore_error)
g_warning ("%s: %s", G_STRFUNC, error->message);
g_error_free (error);
goto exit;