diff options
Diffstat (limited to 'composer/e-msg-composer-hdrs.c')
-rw-r--r-- | composer/e-msg-composer-hdrs.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/composer/e-msg-composer-hdrs.c b/composer/e-msg-composer-hdrs.c index cfadd425f9..b3e8078f3e 100644 --- a/composer/e-msg-composer-hdrs.c +++ b/composer/e-msg-composer-hdrs.c @@ -333,19 +333,19 @@ account_can_send (EAccount *account) { static CamelStore *store; CamelException ex; + gboolean result = FALSE; if (!account->parent_uid) return TRUE; - if (!(store = (CamelStore *) camel_session_get_service (session, e_account_get_string(account, E_ACCOUNT_SOURCE_URL), CAMEL_PROVIDER_STORE, &ex))) { + if (!(store = (CamelStore *) camel_session_get_service (session, e_account_get_string(account, E_ACCOUNT_SOURCE_URL), CAMEL_PROVIDER_STORE, &ex))) camel_exception_clear (&ex); - return FALSE; + else if (store->mode & CAMEL_STORE_WRITE) { + result = TRUE; + g_object_unref (store); } - if (store->mode & CAMEL_STORE_WRITE) - return TRUE; - - return FALSE; + return result; } static GtkWidget * |