diff options
Diffstat (limited to 'mail/session.c')
-rw-r--r-- | mail/session.c | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/mail/session.c b/mail/session.c index d95367d77c..28694f39a1 100644 --- a/mail/session.c +++ b/mail/session.c @@ -125,9 +125,12 @@ auth_callback (CamelAuthCallbackMode mode, char *data, gboolean secret, char *key, *ans, *url; gboolean accept; - url = camel_url_to_string (service->url, CAMEL_URL_HIDE_PASSWORD | CAMEL_URL_HIDE_PARAMS); - key = g_strdup_printf ("%s:%s", url, item); - g_free (url); + if (service) { + url = camel_url_to_string (service->url, CAMEL_URL_HIDE_PASSWORD | CAMEL_URL_HIDE_PARAMS); + key = g_strdup_printf ("%s:%s", url, item); + g_free (url); + } else + key = g_strdup (item); switch (mode) { case CAMEL_AUTHENTICATOR_TELL: |