diff options
author | Matthew Barnes <mbarnes@redhat.com> | 2011-10-22 01:26:07 +0800 |
---|---|---|
committer | Matthew Barnes <mbarnes@redhat.com> | 2011-10-25 00:03:54 +0800 |
commit | 56ebfe2f3f1bbcd05c2ac78821edd06c986b40e6 (patch) | |
tree | 9d042f76db5acba2aaaed47b41c581a06a204883 /modules | |
parent | 8c67e84f9bf1803108f7a004513e37c6ef22d41f (diff) | |
download | gsoc2013-evolution-56ebfe2f3f1bbcd05c2ac78821edd06c986b40e6.tar gsoc2013-evolution-56ebfe2f3f1bbcd05c2ac78821edd06c986b40e6.tar.gz gsoc2013-evolution-56ebfe2f3f1bbcd05c2ac78821edd06c986b40e6.tar.bz2 gsoc2013-evolution-56ebfe2f3f1bbcd05c2ac78821edd06c986b40e6.tar.lz gsoc2013-evolution-56ebfe2f3f1bbcd05c2ac78821edd06c986b40e6.tar.xz gsoc2013-evolution-56ebfe2f3f1bbcd05c2ac78821edd06c986b40e6.tar.zst gsoc2013-evolution-56ebfe2f3f1bbcd05c2ac78821edd06c986b40e6.zip |
Adapt to CamelNetworkSettings changes.
Diffstat (limited to 'modules')
-rw-r--r-- | modules/online-accounts/camel-sasl-xoauth.c | 15 |
1 files changed, 12 insertions, 3 deletions
diff --git a/modules/online-accounts/camel-sasl-xoauth.c b/modules/online-accounts/camel-sasl-xoauth.c index 14ecb29bc4..e2ba57287a 100644 --- a/modules/online-accounts/camel-sasl-xoauth.c +++ b/modules/online-accounts/camel-sasl-xoauth.c @@ -352,21 +352,30 @@ sasl_xoauth_challenge_sync (CamelSasl *sasl, GoaAccount *goa_account; GByteArray *parameters = NULL; CamelService *service; + EAccount *account; CamelURL *url; const gchar *account_id; + const gchar *uid; gchar *xoauth_param = NULL; gboolean success; service = camel_sasl_get_service (sasl); - url = camel_service_get_camel_url (service); - account_id = camel_url_get_param (url, GOA_KEY); - g_return_val_if_fail (account_id != NULL, NULL); + uid = camel_service_get_uid (service); + account = e_get_account_by_uid (uid); + g_return_val_if_fail (account != NULL, NULL); goa_client = goa_client_new_sync (cancellable, error); if (goa_client == NULL) return NULL; + url = camel_url_new (account->store->url, error); + if (url == NULL) + return NULL; + + account_id = camel_url_get_param (url, GOA_KEY); goa_object = sasl_xoauth_get_account_by_id (goa_client, account_id); + camel_url_free (url); + if (goa_object == NULL) { g_set_error_literal ( error, CAMEL_SERVICE_ERROR, |