aboutsummaryrefslogtreecommitdiffstats
path: root/my-evolution/e-summary-weather.c
diff options
context:
space:
mode:
authorIain Holmes <iain@src.gnome.org>2001-10-19 04:17:52 +0800
committerIain Holmes <iain@src.gnome.org>2001-10-19 04:17:52 +0800
commitf19b05e4561a256176bb09367ccbc49add7030d9 (patch)
treef922f5f18a5aa91379178613c416dd10b3c3c6d9 /my-evolution/e-summary-weather.c
parent3755be0a4ca10fdcd53fb50eaa34422ee8dcf1d6 (diff)
downloadgsoc2013-evolution-f19b05e4561a256176bb09367ccbc49add7030d9.tar
gsoc2013-evolution-f19b05e4561a256176bb09367ccbc49add7030d9.tar.gz
gsoc2013-evolution-f19b05e4561a256176bb09367ccbc49add7030d9.tar.bz2
gsoc2013-evolution-f19b05e4561a256176bb09367ccbc49add7030d9.tar.lz
gsoc2013-evolution-f19b05e4561a256176bb09367ccbc49add7030d9.tar.xz
gsoc2013-evolution-f19b05e4561a256176bb09367ccbc49add7030d9.tar.zst
gsoc2013-evolution-f19b05e4561a256176bb09367ccbc49add7030d9.zip
Stuff to try to find the memory corruption
svn path=/trunk/; revision=13769
Diffstat (limited to 'my-evolution/e-summary-weather.c')
-rw-r--r--my-evolution/e-summary-weather.c15
1 files changed, 14 insertions, 1 deletions
diff --git a/my-evolution/e-summary-weather.c b/my-evolution/e-summary-weather.c
index 070e5ed618..0b86471077 100644
--- a/my-evolution/e-summary-weather.c
+++ b/my-evolution/e-summary-weather.c
@@ -364,7 +364,7 @@ open_callback (GnomeVFSAsyncHandle *handle,
(GnomeVFSAsyncReadCallback) read_callback, w);
}
-static gboolean
+gboolean
e_summary_weather_update (ESummary *summary)
{
GList *w;
@@ -379,6 +379,19 @@ e_summary_weather_update (ESummary *summary)
char *uri;
Weather *weather = w->data;
+ if (weather->handle != NULL) {
+ gnome_vfs_async_cancel (weather->handle);
+ weather->handle = NULL;
+ }
+ if (weather->string) {
+ g_string_free (weather->string, TRUE);
+ weather->string = NULL;
+ }
+ if (weather->buffer) {
+ g_free (weather->buffer);
+ weather->buffer = NULL;
+ }
+
uri = g_strdup_printf ("http://weather.noaa.gov/cgi-bin/mgetmetar.pl?cccc=%s", weather->location);
gnome_vfs_async_open (&weather->handle, uri, GNOME_VFS_OPEN_READ,