aboutsummaryrefslogtreecommitdiffstats
path: root/my-evolution/e-summary-rdf.c
diff options
context:
space:
mode:
authorIain Holmes <iain@ximian.com>2001-10-27 07:15:19 +0800
committerEttore Perazzoli <ettore@src.gnome.org>2001-10-27 07:15:19 +0800
commit0b5c3e9f8b92121454a5573f7c3d3467554e6916 (patch)
tree85f8d9b3d79f60708a012d06f5c02d1c06dbaa4a /my-evolution/e-summary-rdf.c
parentc944779866017804bbeb94f9c81af4ffa0eef3ba (diff)
downloadgsoc2013-evolution-0b5c3e9f8b92121454a5573f7c3d3467554e6916.tar
gsoc2013-evolution-0b5c3e9f8b92121454a5573f7c3d3467554e6916.tar.gz
gsoc2013-evolution-0b5c3e9f8b92121454a5573f7c3d3467554e6916.tar.bz2
gsoc2013-evolution-0b5c3e9f8b92121454a5573f7c3d3467554e6916.tar.lz
gsoc2013-evolution-0b5c3e9f8b92121454a5573f7c3d3467554e6916.tar.xz
gsoc2013-evolution-0b5c3e9f8b92121454a5573f7c3d3467554e6916.tar.zst
gsoc2013-evolution-0b5c3e9f8b92121454a5573f7c3d3467554e6916.zip
NULL the handle after a failed open so the offline handler won't think
2001-10-26 Iain Holmes <iain@ximian.com> * e-summary-rdf.c (open_callback): NULL the handle after a failed open so the offline handler won't think they're still open. (e_summary_rdf_set_online): Cancel all the open connections when the summary goes offline. * e-summary-weather.c (open_callback): NULL the handle after a failed open so the offline handler won't think they're still open. (e_summary_weather_set_online): Cancel all the open connections when the summary goes offline. * e-summary.c (e_summary_set_online): Call the callback if it's not NULL. svn path=/trunk/; revision=14183
Diffstat (limited to 'my-evolution/e-summary-rdf.c')
-rw-r--r--my-evolution/e-summary-rdf.c13
1 files changed, 13 insertions, 0 deletions
diff --git a/my-evolution/e-summary-rdf.c b/my-evolution/e-summary-rdf.c
index 97e95a873a..498717e3c1 100644
--- a/my-evolution/e-summary-rdf.c
+++ b/my-evolution/e-summary-rdf.c
@@ -411,6 +411,7 @@ open_callback (GnomeVFSAsyncHandle *handle,
if (result != GNOME_VFS_OK) {
char *str;
+ r->handle = NULL;
g_free (r->html);
str = g_strdup_printf ("<b>%s:</b><br>%s", _("Error downloading RDF"),
r->uri);
@@ -456,6 +457,7 @@ e_summary_rdf_update (ESummary *summary)
rdf->string = NULL;
}
+ g_warning ("Opening %s", rdf->uri);
gnome_vfs_async_open (&rdf->handle, rdf->uri,
GNOME_VFS_OPEN_READ,
(GnomeVFSAsyncOpenCallback) open_callback, rdf);
@@ -581,6 +583,7 @@ e_summary_rdf_set_online (ESummary *summary,
void *data)
{
ESummaryRDF *rdf;
+ GList *p;
rdf = summary->rdf;
if (rdf->online == online) {
@@ -593,6 +596,16 @@ e_summary_rdf_set_online (ESummary *summary,
(GtkFunction) e_summary_rdf_update,
summary);
} else {
+ for (p = rdf->rdfs; p; p = p->next) {
+ RDF *r;
+
+ r = p->data;
+ if (r->handle) {
+ gnome_vfs_async_cancel (r->handle);
+ r->handle = NULL;
+ }
+ }
+
gtk_timeout_remove (rdf->timeout);
rdf->timeout = 0;
}