evolution-data-server r8336 - branches/gnome-2-20/camel



Author: sragavan
Date: Mon Jan  7 05:20:59 2008
New Revision: 8336
URL: http://svn.gnome.org/viewvc/evolution-data-server?rev=8336&view=rev

Log:
2008-01-07  Srinivasa Ragavan <sragavan novell com>

	** Fix for bug #405497 

	* camel-private.h:
	* camel-vee-folder.c: (folder_changed_base),
	(camel_vee_folder_finalise): Don't pass the events, if the object is being 
	destroyed.


Modified:
   branches/gnome-2-20/camel/ChangeLog
   branches/gnome-2-20/camel/camel-private.h
   branches/gnome-2-20/camel/camel-vee-folder.c

Modified: branches/gnome-2-20/camel/ChangeLog
==============================================================================
--- branches/gnome-2-20/camel/ChangeLog	(original)
+++ branches/gnome-2-20/camel/ChangeLog	Mon Jan  7 05:20:59 2008
@@ -1,3 +1,12 @@
+2008-01-07  Srinivasa Ragavan <sragavan novell com>
+
+	** Fix for bug #405497 
+
+	* camel-private.h:
+	* camel-vee-folder.c: (folder_changed_base),
+	(camel_vee_folder_finalise): Don't pass the events, if the object is being 
+	destroyed.
+
 2007-11-23  Milan Crha  <mcrha redhat com>
 
 	** Fix for bug #461979

Modified: branches/gnome-2-20/camel/camel-private.h
==============================================================================
--- branches/gnome-2-20/camel/camel-private.h	(original)
+++ branches/gnome-2-20/camel/camel-private.h	Mon Jan  7 05:20:59 2008
@@ -139,6 +139,7 @@
 
 
 struct _CamelVeeFolderPrivate {
+	gboolean destroyed;
 	GList *folders;			/* lock using subfolder_lock before changing/accessing */
 	GList *folders_changed;		/* for list of folders that have changed between updates */
 	

Modified: branches/gnome-2-20/camel/camel-vee-folder.c
==============================================================================
--- branches/gnome-2-20/camel/camel-vee-folder.c	(original)
+++ branches/gnome-2-20/camel/camel-vee-folder.c	Mon Jan  7 05:20:59 2008
@@ -1443,9 +1443,12 @@
 static void
 folder_changed_base(CamelVeeFolder *vf, CamelFolder *sub, CamelFolderChangeInfo *changes)
 {
+	struct _CamelVeeFolderPrivate *p = _PRIVATE(vf);	
 	struct _folder_changed_msg *m;
 	CamelSession *session = ((CamelService *)((CamelFolder *)vf)->parent_store)->session;
-	
+	if (p->destroyed)
+ 		return; 
+ 	
 	m = camel_session_thread_msg_new(session, &folder_changed_ops, sizeof(*m));
 	m->changes = camel_folder_change_info_new();
 	camel_folder_change_info_cat(m->changes, changes);
@@ -1688,7 +1691,7 @@
 	CamelFolder *folder = (CamelFolder *)obj;
 
 	p = _PRIVATE(obj) = g_malloc0(sizeof(*p));
-
+	
 	folder->folder_flags |= (CAMEL_FOLDER_HAS_SUMMARY_CAPABILITY |
 				 CAMEL_FOLDER_HAS_SEARCH_CAPABILITY);
 
@@ -1714,6 +1717,8 @@
 	struct _CamelVeeFolderPrivate *p = _PRIVATE(vf);
 	CamelVeeFolder *folder_unmatched = vf->parent_vee_store ? vf->parent_vee_store->folder_unmatched : NULL;
 	GList *node;
+	
+	p->destroyed = TRUE;
 
 	/* TODO: there may be other leaks? */
 



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]