diff options
author | Dan Vrátil <dvratil@redhat.com> | 2012-06-15 22:49:26 +0800 |
---|---|---|
committer | Dan Vrátil <dvratil@redhat.com> | 2012-06-18 19:42:39 +0800 |
commit | 88a372b27e655eaaa27e7b806a1adc360b1583b6 (patch) | |
tree | ddefa0742eee8d25137ee4d1e911e2e94565aa37 /mail/e-mail-backend.c | |
parent | 0c2a0824be34b35528b261220d6703b33f5d868c (diff) | |
download | gsoc2013-evolution-88a372b27e655eaaa27e7b806a1adc360b1583b6.tar.gz gsoc2013-evolution-88a372b27e655eaaa27e7b806a1adc360b1583b6.tar.zst gsoc2013-evolution-88a372b27e655eaaa27e7b806a1adc360b1583b6.zip |
Fix some memory leaks
Diffstat (limited to 'mail/e-mail-backend.c')
-rw-r--r-- | mail/e-mail-backend.c | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/mail/e-mail-backend.c b/mail/e-mail-backend.c index 19150cca03..b0e4326088 100644 --- a/mail/e-mail-backend.c +++ b/mail/e-mail-backend.c @@ -654,11 +654,15 @@ mail_backend_folder_changed_cb (MailFolderCache *folder_cache, CamelFolder *folder = NULL; if (mail_folder_cache_get_folder_from_uri ( - folder_cache, folder_uri, &folder)) + folder_cache, folder_uri, &folder)) { if (folder != NULL && !mail_folder_cache_get_folder_info_flags ( - folder_cache, folder, &flags)) + folder_cache, folder, &flags)) { + g_free (folder_uri); g_return_if_reached (); + } + } + if (folder != NULL) g_object_unref (folder); } @@ -667,6 +671,9 @@ mail_backend_folder_changed_cb (MailFolderCache *folder_cache, event, store, folder_uri, new_messages, msg_uid, msg_sender, msg_subject); + if (folder_uri) + g_free (folder_uri); + folder_type = (flags & CAMEL_FOLDER_TYPE_MASK); target->is_inbox = (folder_type == CAMEL_FOLDER_TYPE_INBOX); |