evolution-exchange r1684 - in branches/gnome-2-22: . calendar
- From: mcrha svn gnome org
- To: svn-commits-list gnome org
- Subject: evolution-exchange r1684 - in branches/gnome-2-22: . calendar
- Date: Fri, 13 Jun 2008 06:23:12 +0000 (UTC)
Author: mcrha
Date: Fri Jun 13 06:23:12 2008
New Revision: 1684
URL: http://svn.gnome.org/viewvc/evolution-exchange?rev=1684&view=rev
Log:
2008-06-13 Milan Crha <mcrha redhat com>
** Fix for bug #402752
* calendar/e-cal-backend-exchange.c: (get_exchange_comp),
(e_cal_backend_exchange_add_object),
(e_cal_backend_exchange_modify_object):
* calendar/e-cal-backend-exchange-calendar.c: (add_ical):
Prevent crash when got a component without set UID.
Modified:
branches/gnome-2-22/ChangeLog
branches/gnome-2-22/calendar/e-cal-backend-exchange-calendar.c
branches/gnome-2-22/calendar/e-cal-backend-exchange.c
Modified: branches/gnome-2-22/calendar/e-cal-backend-exchange-calendar.c
==============================================================================
--- branches/gnome-2-22/calendar/e-cal-backend-exchange-calendar.c (original)
+++ branches/gnome-2-22/calendar/e-cal-backend-exchange-calendar.c Fri Jun 13 06:23:12 2008
@@ -216,6 +216,11 @@
if (!icalcomp)
return FALSE;
+ if (!icalcomponent_get_uid (icalcomp)) {
+ icalcomponent_free (icalcomp);
+ return FALSE;
+ }
+
kind = icalcomponent_isa (icalcomp);
if (kind == ICAL_VEVENT_COMPONENT) {
if (receipts) {
Modified: branches/gnome-2-22/calendar/e-cal-backend-exchange.c
==============================================================================
--- branches/gnome-2-22/calendar/e-cal-backend-exchange.c (original)
+++ branches/gnome-2-22/calendar/e-cal-backend-exchange.c Fri Jun 13 06:23:12 2008
@@ -621,6 +621,9 @@
d(printf("ecbe_add_object(%p, %s, %s)\n", cbex, href, lastmod));
uid = icalcomponent_get_uid (comp);
+ if (!uid)
+ return FALSE;
+
ecomp = g_hash_table_lookup (cbex->priv->objects, uid);
is_instance = (icalcomponent_get_first_property (comp, ICAL_RECURRENCEID_PROPERTY) != NULL);
@@ -721,6 +724,9 @@
FALSE);
uid = icalcomponent_get_uid (comp);
+ if (!uid)
+ return FALSE;
+
rid = icalcomponent_get_recurrenceid (comp);
ecomp = g_hash_table_lookup (cbex->priv->objects, uid);
@@ -808,6 +814,9 @@
{
ECalBackendExchangeComponent *ecomp;
+ if (!uid)
+ return NULL;
+
ecomp = g_hash_table_lookup (cbex->priv->objects, uid);
if (ecomp)
return ecomp;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]