diff options
Diffstat (limited to 'camel/providers')
-rw-r--r-- | camel/providers/imap/camel-imap-store.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/camel/providers/imap/camel-imap-store.c b/camel/providers/imap/camel-imap-store.c index ec65d499b3..c13a584a33 100644 --- a/camel/providers/imap/camel-imap-store.c +++ b/camel/providers/imap/camel-imap-store.c @@ -464,6 +464,14 @@ imap_connect (CamelService *service, CamelException *ex) } } + if (!store->connected) { + /* Some servers (eg, courier) will disconnect on + * a bad password. So reconnect here. + */ + if (!connect_to_server (service, ex)) + return NULL; + } + if (authtype) authenticated = try_auth (store, authtype->authproto, ex); else { |