diff options
Diffstat (limited to 'my-evolution')
-rw-r--r-- | my-evolution/ChangeLog | 7 | ||||
-rw-r--r-- | my-evolution/e-summary-weather.c | 13 |
2 files changed, 17 insertions, 3 deletions
diff --git a/my-evolution/ChangeLog b/my-evolution/ChangeLog index d35630efd3..7079382892 100644 --- a/my-evolution/ChangeLog +++ b/my-evolution/ChangeLog @@ -1,3 +1,10 @@ +2002-10-21 Ettore Perazzoli <ettore@ximian.com> + + * e-summary-weather.c (e_summary_weather_reconfigure): NULL the + ->weathers member before freeing the list items. Otherwise + soup_message_cancel() might invoke the refresh function while we + are freeing things on the list, and crash. [#31639] + 2002-09-26 Ettore Perazzoli <ettore@ximian.com> * e-summary-mail.c (e_summary_mail_generate_html): Generate HTML diff --git a/my-evolution/e-summary-weather.c b/my-evolution/e-summary-weather.c index 6391fa7c3e..667853a8b0 100644 --- a/my-evolution/e-summary-weather.c +++ b/my-evolution/e-summary-weather.c @@ -759,6 +759,7 @@ e_summary_weather_reconfigure (ESummary *summary) { ESummaryWeather *weather; GList *old, *p; + GList *weather_list; g_return_if_fail (summary != NULL); g_return_if_fail (IS_E_SUMMARY (summary)); @@ -768,14 +769,20 @@ e_summary_weather_reconfigure (ESummary *summary) /* Stop timeout so it doesn't occur while we're changing stuff*/ gtk_timeout_remove (weather->timeout); - for (old = weather->weathers; old; old = old->next) { + /* Clear the weather list before doing weather_free() on each of them + because otherwise soup_message_cancel() could invoke the refresh + function just while we are freeing things. [#31639] */ + weather_list = weather->weathers; + weather->weathers = NULL; + + for (old = weather_list; old != NULL; old = old->next) { Weather *w; w = old->data; weather_free (w); } - g_list_free (weather->weathers); - weather->weathers = NULL; + g_list_free (weather_list); + for (p = summary->preferences->stations; p; p = p->next) { e_summary_weather_add_location (summary, p->data); } |