diff options
Diffstat (limited to 'extra/evolution-data-server/fix-google-2fa-3.patch')
-rw-r--r-- | extra/evolution-data-server/fix-google-2fa-3.patch | 48 |
1 files changed, 48 insertions, 0 deletions
diff --git a/extra/evolution-data-server/fix-google-2fa-3.patch b/extra/evolution-data-server/fix-google-2fa-3.patch new file mode 100644 index 000000000..a5c6ca324 --- /dev/null +++ b/extra/evolution-data-server/fix-google-2fa-3.patch @@ -0,0 +1,48 @@ +From cc9fb7d15ce3983fc36487d2856e5fd14b341725 Mon Sep 17 00:00:00 2001 +From: Matthew Barnes <mbarnes@redhat.com> +Date: Tue, 09 Jul 2013 15:49:09 +0000 +Subject: google: Minor module cleanups. + +--- +diff --git a/modules/google-backend/module-google-backend.c b/modules/google-backend/module-google-backend.c +index d5684bb..cbd7bd2 100644 +--- a/modules/google-backend/module-google-backend.c ++++ b/modules/google-backend/module-google-backend.c +@@ -100,19 +100,17 @@ google_backend_contacts_update_auth_method (ESource *source) + EOAuth2Support *oauth2_support; + ESourceAuthentication *extension; + const gchar *extension_name; +- +- extension_name = E_SOURCE_EXTENSION_AUTHENTICATION; +- extension = e_source_get_extension (source, extension_name); ++ const gchar *method; + + oauth2_support = e_server_side_source_ref_oauth2_support ( + E_SERVER_SIDE_SOURCE (source)); +- if (oauth2_support != NULL) { +- e_source_authentication_set_method (extension, "OAuth2"); +- g_object_unref (oauth2_support); +- return; +- } + +- e_source_authentication_set_method (extension, "ClientLogin"); ++ extension_name = E_SOURCE_EXTENSION_AUTHENTICATION; ++ extension = e_source_get_extension (source, extension_name); ++ method = (oauth2_support != NULL) ? "OAuth2" : "ClientLogin"; ++ e_source_authentication_set_method (extension, method); ++ ++ g_clear_object (&oauth2_support); + } + + static void +@@ -178,7 +176,8 @@ google_backend_add_calendar (ECollectionBackend *backend) + + g_get_current_time (&today_tv); + today = g_time_val_to_iso8601 (&today_tv); +- e_source_alarms_set_last_notified (E_SOURCE_ALARMS (extension), today); ++ e_source_alarms_set_last_notified ( ++ E_SOURCE_ALARMS (extension), today); + g_free (today); + } + + |