[evolution] Bug #638245 - Crash when printing Work Week view
- From: Milan Crha <mcrha src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [evolution] Bug #638245 - Crash when printing Work Week view
- Date: Thu, 6 Jan 2011 13:26:45 +0000 (UTC)
commit 81f14a09c8624937c752ae315a66928eb31a2f6d
Author: Milan Crha <mcrha redhat com>
Date: Thu Jan 6 14:26:34 2011 +0100
Bug #638245 - Crash when printing Work Week view
calendar/gui/print.c | 10 ++++++----
1 files changed, 6 insertions(+), 4 deletions(-)
---
diff --git a/calendar/gui/print.c b/calendar/gui/print.c
index 051dbc7..5c62d3c 100644
--- a/calendar/gui/print.c
+++ b/calendar/gui/print.c
@@ -1356,7 +1356,7 @@ print_day_details (GtkPrintContext *context, GnomeCalendar *gcal, time_t whence,
EDayViewEvent *event;
PangoFontDescription *font;
time_t start, end;
- struct pdinfo pdi;
+ struct pdinfo pdi = { 0 };
gint rows_in_top_display, i;
gdouble font_size, max_font_size;
cairo_t *cr;
@@ -1908,7 +1908,7 @@ print_week_summary (GtkPrintContext *context, GnomeCalendar *gcal,
{
icaltimezone *zone;
EWeekViewEvent *event;
- struct psinfo psi;
+ struct psinfo psi = { 0 };
time_t day_start;
gint rows_per_day[E_WEEK_VIEW_MAX_WEEKS * 7], day, event_num;
GArray *spans;
@@ -2431,7 +2431,7 @@ print_work_week_day_details (GtkPrintContext *context, GnomeCalendar *gcal,
EDayViewEvent *event;
PangoFontDescription *font;
time_t start, end;
- struct pdinfo pdi;
+ struct pdinfo pdi = { 0 };
gint rows_in_top_display, i;
gdouble font_size, max_font_size;
cairo_t *cr;
@@ -2459,6 +2459,7 @@ print_work_week_day_details (GtkPrintContext *context, GnomeCalendar *gcal,
pdi.start_minute_offset = pdi.start_hour * 60;
pdi.end_minute_offset = pdi.end_hour * 60;
pdi.use_24_hour_format = e_cal_model_get_use_24_hour_format (model);
+ pdi.zone = e_cal_model_get_timezone (model);
/* Get the events from the server. */
e_cal_model_generate_instances (model, start, end, print_day_details_cb, &pdi);
@@ -2627,7 +2628,7 @@ print_work_week_view (GtkPrintContext *context, GnomeCalendar *gcal, time_t date
gint i, days = 5;
gchar buf[100];
const gint LONG_EVENT_OFFSET = 6;
- struct pdinfo pdi;
+ struct pdinfo pdi = { 0 };
struct tm tm;
gdouble day_width, day_x;
ECalModel *model;
@@ -2648,6 +2649,7 @@ print_work_week_view (GtkPrintContext *context, GnomeCalendar *gcal, time_t date
pdi.days_shown = days;
pdi.start_hour = e_cal_model_get_work_day_start_hour (model);
pdi.end_hour = e_cal_model_get_work_day_end_hour (model);
+ pdi.zone = zone;
e_cal_model_generate_instances (model, start, end,
print_work_week_view_cb, &pdi);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]