diff options
author | Milan Crha <mcrha@redhat.com> | 2011-06-15 15:08:21 +0200 |
---|---|---|
committer | Milan Crha <mcrha@redhat.com> | 2011-06-15 15:08:21 +0200 |
commit | 8a0e80ed364117355132901caa94a737997674d4 (patch) | |
tree | a530c5aab1bd38b338c2a97d5c21f4b43336b74a | |
parent | 7b2d680e89f043b024d8b2b7c5c8a2150a6e2f99 (diff) | |
download | evolution-data-server-8a0e80ed364117355132901caa94a737997674d4.tar.gz |
Bug #565961 - Crash with recurring all-day event
-rw-r--r-- | calendar/libecal/e-cal.c | 16 |
1 files changed, 11 insertions, 5 deletions
diff --git a/calendar/libecal/e-cal.c b/calendar/libecal/e-cal.c index f30a4da11..c82845319 100644 --- a/calendar/libecal/e-cal.c +++ b/calendar/libecal/e-cal.c @@ -3034,12 +3034,15 @@ try_again: } } else { ECalComponentDateTime datetime; - icaltimezone *start_zone; + icaltimezone *start_zone = NULL; struct instances_info *instances_hold; /* Get the start timezone */ e_cal_component_get_dtstart (comp, &datetime); - e_cal_get_timezone (ecal, datetime.tzid, &start_zone, NULL); + if (datetime.tzid) + e_cal_get_timezone (ecal, datetime.tzid, &start_zone, NULL); + else + start_zone = NULL; e_cal_component_free_datetime (&datetime); instances_hold = g_new0 (struct instances_info, 1); @@ -3160,7 +3163,7 @@ e_cal_generate_instances_for_object (ECal *ecal, icalcomponent *icalcomp, gboolean result; GList *instances = NULL; ECalComponentDateTime datetime; - icaltimezone *start_zone; + icaltimezone *start_zone = NULL; struct instances_info *instances_hold; gboolean is_single_instance = FALSE; @@ -3191,7 +3194,10 @@ e_cal_generate_instances_for_object (ECal *ecal, icalcomponent *icalcomp, /* Get the start timezone */ e_cal_component_get_dtstart (comp, &datetime); - e_cal_get_timezone (ecal, datetime.tzid, &start_zone, NULL); + if (datetime.tzid) + e_cal_get_timezone (ecal, datetime.tzid, &start_zone, NULL); + else + start_zone = NULL; e_cal_component_free_datetime (&datetime); instances_hold = g_new0 (struct instances_info, 1); @@ -3471,7 +3477,7 @@ foreach_tzid_callback (icalparameter *param, gpointer cbdata) ForeachTZIDCallbackData *data = cbdata; ECalPrivate *priv; const gchar *tzid; - icaltimezone *zone; + icaltimezone *zone = NULL; icalcomponent *vtimezone_comp; gchar *vtimezone_as_string; |