evolution r34893 - in trunk/calendar: . gui



Author: mcrha
Date: Fri Jan 25 12:38:03 2008
New Revision: 34893
URL: http://svn.gnome.org/viewvc/evolution?rev=34893&view=rev

Log:
2008-01-25  Milan Crha  <mcrha redhat com>

	** Fix for bug #510409

	* gui/e-memos.c: (obtain_list_of_components):
	* gui/e-tasks.c: (obtain_list_of_components):
	* gui/e-calendar-table.c: (e_calendar_table_copy_clipboard):
	* gui/e-memo-table.c: (e_memo_table_copy_clipboard):
	Do not free memmory owned by libical.
	* gui/e-week-view.c: (e_week_view_reshape_events):
	Free memory before assigning NULL.



Modified:
   trunk/calendar/ChangeLog
   trunk/calendar/gui/e-calendar-table.c
   trunk/calendar/gui/e-memo-table.c
   trunk/calendar/gui/e-memos.c
   trunk/calendar/gui/e-tasks.c
   trunk/calendar/gui/e-week-view.c

Modified: trunk/calendar/gui/e-calendar-table.c
==============================================================================
--- trunk/calendar/gui/e-calendar-table.c	(original)
+++ trunk/calendar/gui/e-calendar-table.c	Fri Jan 25 12:38:03 2008
@@ -873,7 +873,9 @@
 	if (!gtk_clipboard_set_with_data(clipboard, target_types, n_target_types,
 					 clipboard_get_calendar_cb,
 					 NULL, comp_str)) {
-		g_free (comp_str);
+
+		/* do not free this pointer, it owns libical */
+		/* g_free (comp_str); */
 	} else {
 		gtk_clipboard_set_can_store (clipboard, target_types + 1, n_target_types - 1);
 	}

Modified: trunk/calendar/gui/e-memo-table.c
==============================================================================
--- trunk/calendar/gui/e-memo-table.c	(original)
+++ trunk/calendar/gui/e-memo-table.c	Fri Jan 25 12:38:03 2008
@@ -602,7 +602,8 @@
 	if (!gtk_clipboard_set_with_data(clipboard, target_types, n_target_types,
 					 clipboard_get_calendar_cb,
 					 NULL, comp_str)) {
-		g_free (comp_str);
+		/* do not free this pointer, it owns libical */
+		/* g_free (comp_str); */
 	} else {
 		gtk_clipboard_set_can_store (clipboard, target_types + 1, n_target_types - 1);
 	}

Modified: trunk/calendar/gui/e-memos.c
==============================================================================
--- trunk/calendar/gui/e-memos.c	(original)
+++ trunk/calendar/gui/e-memos.c	Fri Jan 25 12:38:03 2008
@@ -417,7 +417,9 @@
 			const char *source_uid = e_source_peek_uid (source);
 
 			*list = g_slist_prepend (*list, g_strdup_printf ("%s\n%s", source_uid, comp_str));
-			g_free (comp_str);
+
+			/* do not free this pointer, it owns libical */
+			/* g_free (comp_str); */
 		}
 
 		icalcomponent_free (vcal);

Modified: trunk/calendar/gui/e-tasks.c
==============================================================================
--- trunk/calendar/gui/e-tasks.c	(original)
+++ trunk/calendar/gui/e-tasks.c	Fri Jan 25 12:38:03 2008
@@ -514,7 +514,9 @@
 			const char *source_uid = e_source_peek_uid (source);
 
 			*list = g_slist_prepend (*list, g_strdup_printf ("%s\n%s", source_uid, comp_str));
-			g_free (comp_str);
+
+			/* do not free this pointer, it owns libical */
+			/* g_free (comp_str); */
 		}
 
 		icalcomponent_free (vcal);

Modified: trunk/calendar/gui/e-week-view.c
==============================================================================
--- trunk/calendar/gui/e-week-view.c	(original)
+++ trunk/calendar/gui/e-week-view.c	Fri Jan 25 12:38:03 2008
@@ -2518,6 +2518,7 @@
 				EWeekViewEventSpan *span;
 				span = &g_array_index (week_view->spans, EWeekViewEventSpan, event->spans_index + span_num);
 				e_canvas_item_grab_focus (span->text_item, TRUE);
+				g_free (week_view->last_edited_comp_string);
 				week_view->last_edited_comp_string = NULL;
 			}
 		}



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