aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--calendar/ChangeLog9
-rw-r--r--calendar/gui/e-cal-model-calendar.c10
-rw-r--r--calendar/gui/e-cal-model.c10
3 files changed, 18 insertions, 11 deletions
diff --git a/calendar/ChangeLog b/calendar/ChangeLog
index 4d45314a24..6906c37fac 100644
--- a/calendar/ChangeLog
+++ b/calendar/ChangeLog
@@ -1,4 +1,11 @@
-2003-11-18 <jpr@ximian.com>
+2003-11-18 JP Rosevear <jpr@ximian.com>
+
+ * gui/e-cal-model.c (get_dtstart): make sure the timezone value is
+ sane
+
+ * gui/e-cal-model-calendar.c (get_dtend): ditto
+
+2003-11-18 JP Rosevear <jpr@ximian.com>
* gui/calendar-config.h: add protos
diff --git a/calendar/gui/e-cal-model-calendar.c b/calendar/gui/e-cal-model-calendar.c
index 76462064a2..e41160770a 100644
--- a/calendar/gui/e-cal-model-calendar.c
+++ b/calendar/gui/e-cal-model-calendar.c
@@ -126,11 +126,11 @@ get_dtend (ECalModelComponent *comp_data)
comp_data->dtend = g_new0 (ECellDateEditValue, 1);
comp_data->dtend->tt = tt_end;
- /* FIXME: handle errors */
- e_cal_get_timezone (comp_data->client,
- icaltime_get_tzid (tt_end),
- &zone, NULL);
- comp_data->dtend->zone = zone;
+ if (e_cal_get_timezone (comp_data->client, icaltime_get_tzid (tt_end),
+ &zone, NULL))
+ comp_data->dtend->zone = zone;
+ else
+ comp_data->dtend->zone = NULL;
}
return comp_data->dtend;
diff --git a/calendar/gui/e-cal-model.c b/calendar/gui/e-cal-model.c
index 699a6d43b2..0073a7cac8 100644
--- a/calendar/gui/e-cal-model.c
+++ b/calendar/gui/e-cal-model.c
@@ -352,11 +352,11 @@ get_dtstart (ECalModel *model, ECalModelComponent *comp_data)
comp_data->dtstart = g_new0 (ECellDateEditValue, 1);
comp_data->dtstart->tt = tt_start;
- /* FIXME: handle errors */
- e_cal_get_timezone (comp_data->client,
- icaltime_get_tzid (tt_start),
- &zone, NULL);
- comp_data->dtstart->zone = zone;
+ if (e_cal_get_timezone (comp_data->client, icaltime_get_tzid (tt_start),
+ &zone, NULL))
+ comp_data->dtstart->zone = zone;
+ else
+ comp_data->dtstart->zone = NULL;
}
return comp_data->dtstart;