aboutsummaryrefslogtreecommitdiffstats
path: root/plugins/itip-formatter
diff options
context:
space:
mode:
authorSrinivasa Ragavan <sragavan@src.gnome.org>2007-08-06 13:04:06 +0800
committerSrinivasa Ragavan <sragavan@src.gnome.org>2007-08-06 13:04:06 +0800
commit771c2a1f0266331a9b9250ee391fca88dd545b66 (patch)
tree50272f4af75558b37f50f95ed98b58480809d337 /plugins/itip-formatter
parent7bea13fa412f69f5923e9d3835769302f466bc9b (diff)
downloadgsoc2013-evolution-771c2a1f0266331a9b9250ee391fca88dd545b66.tar
gsoc2013-evolution-771c2a1f0266331a9b9250ee391fca88dd545b66.tar.gz
gsoc2013-evolution-771c2a1f0266331a9b9250ee391fca88dd545b66.tar.bz2
gsoc2013-evolution-771c2a1f0266331a9b9250ee391fca88dd545b66.tar.lz
gsoc2013-evolution-771c2a1f0266331a9b9250ee391fca88dd545b66.tar.xz
gsoc2013-evolution-771c2a1f0266331a9b9250ee391fca88dd545b66.tar.zst
gsoc2013-evolution-771c2a1f0266331a9b9250ee391fca88dd545b66.zip
** Fix for bug #460326
svn path=/trunk/; revision=33951
Diffstat (limited to 'plugins/itip-formatter')
-rw-r--r--plugins/itip-formatter/ChangeLog7
-rw-r--r--plugins/itip-formatter/itip-formatter.c9
2 files changed, 16 insertions, 0 deletions
diff --git a/plugins/itip-formatter/ChangeLog b/plugins/itip-formatter/ChangeLog
index 8e2e2e3aef..5394bc2148 100644
--- a/plugins/itip-formatter/ChangeLog
+++ b/plugins/itip-formatter/ChangeLog
@@ -1,3 +1,10 @@
+2007-08-06 Srinivasa Ragavan <sragavan@novell.com>
+
+ ** Fix for bug #460326
+
+ * itip-formatter.c: (extract_itip_data): If the vcalendar isn't there
+ don't crash but report invalid.
+
2007-07-20 Claude Paroz <claude@2xlibre.net>
* itip-view.c: (set_tasklist_sender_text): Added omitted %s formatter.
diff --git a/plugins/itip-formatter/itip-formatter.c b/plugins/itip-formatter/itip-formatter.c
index 420fe6006f..6e85300a3d 100644
--- a/plugins/itip-formatter/itip-formatter.c
+++ b/plugins/itip-formatter/itip-formatter.c
@@ -1339,6 +1339,15 @@ extract_itip_data (FormatItipPObject *pitip, GtkContainer *container)
mem = camel_stream_mem_new ();
camel_data_wrapper_decode_to_stream (content, mem);
+ if (((CamelStreamMem *) mem)->buffer->len == 0) {
+ camel_object_unref (mem);
+ set_itip_error (pitip, container,
+ _("The calendar attached is not valid"),
+ _("The message claims to contain a calendar, but the calendar is not a valid iCalendar."));
+
+ return FALSE;
+ }
+
pitip->vcalendar = g_strndup ((char *)((CamelStreamMem *) mem)->buffer->data, ((CamelStreamMem *) mem)->buffer->len);
camel_object_unref (mem);