aboutsummaryrefslogtreecommitdiffstats
path: root/mail/em-folder-utils.c
diff options
context:
space:
mode:
authorMatthew Barnes <mbarnes@redhat.com>2013-11-17 06:49:52 +0800
committerMatthew Barnes <mbarnes@redhat.com>2013-11-17 08:24:02 +0800
commitc134c41bcdd826228f697c11ab4b375b65bd97fa (patch)
tree025bdfd6f3627aa978f672c12620dd676ee6859b /mail/em-folder-utils.c
parent19708882803f5dbd763b202da297c8cbf8f6b7f7 (diff)
downloadgsoc2013-evolution-c134c41bcdd826228f697c11ab4b375b65bd97fa.tar
gsoc2013-evolution-c134c41bcdd826228f697c11ab4b375b65bd97fa.tar.gz
gsoc2013-evolution-c134c41bcdd826228f697c11ab4b375b65bd97fa.tar.bz2
gsoc2013-evolution-c134c41bcdd826228f697c11ab4b375b65bd97fa.tar.lz
gsoc2013-evolution-c134c41bcdd826228f697c11ab4b375b65bd97fa.tar.xz
gsoc2013-evolution-c134c41bcdd826228f697c11ab4b375b65bd97fa.tar.zst
gsoc2013-evolution-c134c41bcdd826228f697c11ab4b375b65bd97fa.zip
EMFolderTreeModel: Declare the CamelStore column as an object type.
Declaring the CamelStore column as a raw pointer type dates back to before Camel was GObject-based. The problem is the CamelStore could be finalized while the tree model still has a pointer to it, leaving behind dangling pointers in the tree model which could cause a crash. Declaring the column type in the column enum turned out to be a good idea, as it makes code that needs updated easy to find. This renames the enum value from COL_POINTER_CAMEL_STORE to COL_OBJECT_CAMEL_STORE.
Diffstat (limited to 'mail/em-folder-utils.c')
-rw-r--r--mail/em-folder-utils.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/mail/em-folder-utils.c b/mail/em-folder-utils.c
index 5633abc8f8..93225d584b 100644
--- a/mail/em-folder-utils.c
+++ b/mail/em-folder-utils.c
@@ -450,10 +450,11 @@ emfu_copy_folder_exclude (EMFolderTree *tree,
gtk_tree_model_get (
model, iter,
COL_UINT_FLAGS, &flags,
- COL_POINTER_CAMEL_STORE, &store, -1);
+ COL_OBJECT_CAMEL_STORE, &store, -1);
uid = camel_service_get_uid (CAMEL_SERVICE (store));
tovfolder = (g_strcmp0 (uid, E_MAIL_SESSION_VFOLDER_UID) == 0);
+ g_object_unref (store);
/* moving from vfolder to normal- not allowed */
if (fromvfolder && !tovfolder && cfd->delete)