[evolution-data-server/gnome-3-22] Bug 774841 - [EWebDAVDiscover] One part failure caused credentials reject
- From: Milan Crha <mcrha src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [evolution-data-server/gnome-3-22] Bug 774841 - [EWebDAVDiscover] One part failure caused credentials reject
- Date: Thu, 1 Dec 2016 18:15:01 +0000 (UTC)
commit b87b756825c65b17ece1f2a6eb1faa70f31372a3
Author: Milan Crha <mcrha redhat com>
Date: Thu Dec 1 19:14:46 2016 +0100
Bug 774841 - [EWebDAVDiscover] One part failure caused credentials reject
libedataserver/e-webdav-discover.c | 6 +++++-
modules/google-backend/module-google-backend.c | 2 ++
modules/owncloud-backend/module-owncloud-backend.c | 2 ++
3 files changed, 9 insertions(+), 1 deletions(-)
---
diff --git a/libedataserver/e-webdav-discover.c b/libedataserver/e-webdav-discover.c
index 8fe1e3a..4a50a0f 100644
--- a/libedataserver/e-webdav-discover.c
+++ b/libedataserver/e-webdav-discover.c
@@ -443,8 +443,12 @@ e_webdav_discover_check_successful (SoupMessage *message,
error_code = G_IO_ERROR_NOT_FOUND;
break;
case SOUP_STATUS_UNAUTHORIZED:
- case SOUP_STATUS_PAYMENT_REQUIRED:
case SOUP_STATUS_FORBIDDEN:
+ g_set_error (
+ error, SOUP_HTTP_ERROR, message->status_code,
+ _("HTTP Error: %s"), message->reason_phrase);
+ return FALSE;
+ case SOUP_STATUS_PAYMENT_REQUIRED:
error_code = G_IO_ERROR_PERMISSION_DENIED;
break;
case SOUP_STATUS_REQUEST_TIMEOUT:
diff --git a/modules/google-backend/module-google-backend.c b/modules/google-backend/module-google-backend.c
index d17d76c..acd6cc8 100644
--- a/modules/google-backend/module-google-backend.c
+++ b/modules/google-backend/module-google-backend.c
@@ -550,6 +550,8 @@ google_backend_authenticate_sync (EBackend *backend,
g_hash_table_foreach (known_sources, google_remove_unknown_sources_cb, server);
g_object_unref (server);
}
+
+ g_clear_error (&local_error);
}
if (local_error == NULL) {
diff --git a/modules/owncloud-backend/module-owncloud-backend.c
b/modules/owncloud-backend/module-owncloud-backend.c
index f825835..7e77e8b 100644
--- a/modules/owncloud-backend/module-owncloud-backend.c
+++ b/modules/owncloud-backend/module-owncloud-backend.c
@@ -382,6 +382,8 @@ owncloud_backend_authenticate_sync (EBackend *backend,
g_hash_table_foreach (known_sources, owncloud_remove_unknown_sources_cb, server);
g_object_unref (server);
}
+
+ g_clear_error (&local_error);
}
if (local_error == NULL) {
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]