From ae18a1bad11a55cb52749ca78f4c0ffb9be71475 Mon Sep 17 00:00:00 2001 From: Shreyas Srinivasan Date: Thu, 21 Jul 2005 07:00:54 +0000 Subject: Use camel_object_unref instead of g_object_unref. 2005-07-21 Shreyas Srinivasan * e-msg-composer-hdrs.c (account_can_send): Use camel_object_unref instead of g_object_unref. svn path=/trunk/; revision=29823 --- composer/ChangeLog | 7 ++++++- composer/e-msg-composer-hdrs.c | 8 ++++---- 2 files changed, 10 insertions(+), 5 deletions(-) diff --git a/composer/ChangeLog b/composer/ChangeLog index 03dacd6f1c..7251c68633 100644 --- a/composer/ChangeLog +++ b/composer/ChangeLog @@ -1,6 +1,11 @@ +2005-07-21 Shreyas Srinivasan + + * e-msg-composer-hdrs.c (account_can_send): Use camel_object_unref + instead of g_object_unref. + 2005-07-15 Shreyas Srinivasan - * e-msg-composer-hdrs.c: (account_can_send) unref the store which + * e-msg-composer-hdrs.c (account_can_send): unref the store which was being leaked. 2005-07-14 Not Zed diff --git a/composer/e-msg-composer-hdrs.c b/composer/e-msg-composer-hdrs.c index b3e8078f3e..1361c0dfff 100644 --- a/composer/e-msg-composer-hdrs.c +++ b/composer/e-msg-composer-hdrs.c @@ -338,13 +338,13 @@ account_can_send (EAccount *account) 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); - else if (store->mode & CAMEL_STORE_WRITE) { + return result; + } else if (store->mode & CAMEL_STORE_WRITE) result = TRUE; - g_object_unref (store); - } + camel_object_unref (store); return result; } -- cgit