aboutsummaryrefslogtreecommitdiffstats
path: root/my-evolution/e-summary-weather.c
diff options
context:
space:
mode:
authorEttore Perazzoli <ettore@src.gnome.org>2002-10-21 23:21:10 +0800
committerEttore Perazzoli <ettore@src.gnome.org>2002-10-21 23:21:10 +0800
commit29a63b4a136c2c1c7f824a333e4752987ee342b7 (patch)
tree4d971389a3ce2e4580ee2941ca9e09c81e35a12e /my-evolution/e-summary-weather.c
parent58573777e83d81da42285c576f95d588d27b224d (diff)
downloadgsoc2013-evolution-29a63b4a136c2c1c7f824a333e4752987ee342b7.tar.gz
gsoc2013-evolution-29a63b4a136c2c1c7f824a333e4752987ee342b7.tar.zst
gsoc2013-evolution-29a63b4a136c2c1c7f824a333e4752987ee342b7.zip
(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] svn path=/trunk/; revision=18398
Diffstat (limited to 'my-evolution/e-summary-weather.c')
-rw-r--r--my-evolution/e-summary-weather.c13
1 files changed, 10 insertions, 3 deletions
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);
}
td>2-4/+4 * Upgrade ASTK to 1.6.2-1.thierry2008-07-138-66/+47 * - Remove unneeded dependency from gtk12/gtk20 [1]miwi2008-04-201-6/+6 * Chase master-site's reorganization.thierry2008-01-191-1/+1 * - Upgrade ASTK to 1.5.5-1;thierry2008-01-133-22/+47 * - Upgrade to 1.5.2-1;thierry2007-07-014-12/+35 * A sweeping commit: unbreak "make index" if WITH_BASH=YES is defined.bsam2007-06-061-4/+0 * - Welcome X.org 7.2 \o/.flz2007-05-201-1/+1 * Trap an exception and set a default fqn when gethostbyaddr fails withthierry2007-02-182-9/+21 * Chase a silent update (no impact for FreeBSD).thierry2007-01-123-22/+27 * Upgrade to 1.5.0-1.thierry2006-12-264-60/+69 * Upgrade to 1.3.3-1.thierry2006-07-073-19/+7 * remove USE_REINPLACE for all ports with categories starting with Cedwin2006-05-041-1/+0 * Replace ugly "@unexec rmdir %D... 2>/dev/null || true" with @dirrmtryedwin2006-01-221-2/+2 * Upgrade to 1.3.0-1.thierry2006-01-165-34/+62