[evolution-patches] Patch for Defect #56613



Hi,

Looks like not cheking for ESource being NULL is cauisng 
Evolution crash.

Please have a look at the attached patch.

Thanks,
Sushma.
Index: calendar-component.c
===================================================================
RCS file: /cvs/gnome/evolution/calendar/gui/calendar-component.c,v
retrieving revision 1.154
diff -u -r1.154 calendar-component.c
--- calendar-component.c	26 Mar 2004 20:38:03 -0000	1.154
+++ calendar-component.c	7 Apr 2004 10:34:04 -0000
@@ -238,7 +238,7 @@
 		ESource *source;
 
 		source = e_source_list_peek_source_by_uid (priv->task_source_list, uid);
-		if (!is_in_uids (uids_selected, source))
+		if (source && !is_in_uids (uids_selected, source))
 			gnome_calendar_remove_source (priv->calendar, E_CAL_SOURCE_TYPE_TODO, source);
 		
 		g_free (uid);
@@ -251,7 +251,7 @@
 		ESource *source;
 
 		source = e_source_list_peek_source_by_uid (priv->task_source_list, uid);
-		if (!gnome_calendar_add_source (priv->calendar, E_CAL_SOURCE_TYPE_TODO, source))
+		if (source && !gnome_calendar_add_source (priv->calendar, E_CAL_SOURCE_TYPE_TODO, source))
 			/* FIXME do something */;
 	}
 


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