summaryrefslogtreecommitdiff
path: root/kolabformatV2
diff options
context:
space:
mode:
authorChristian Mollekopf <mollekopf@kolabsys.com>2012-08-13 10:14:43 (GMT)
committerChristian Mollekopf <mollekopf@kolabsys.com>2012-08-13 10:14:43 (GMT)
commite77273b73381f722d06b0a870264251f4e620d70 (patch)
tree0cc0addbb9105a4accd06b5445313bca45e1bd35 /kolabformatV2
parenta6fef072bb9ffc373784f966abfd7e8bba20d5b2 (diff)
downloadlibkolab-e77273b73381f722d06b0a870264251f4e620d70.tar.gz
Don't crash when invalid pointers are being passed in + tests. BUG 904
Diffstat (limited to 'kolabformatV2')
-rw-r--r--kolabformatV2/incidence.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/kolabformatV2/incidence.cpp b/kolabformatV2/incidence.cpp
index 4ac7a3e..f627334 100644
--- a/kolabformatV2/incidence.cpp
+++ b/kolabformatV2/incidence.cpp
@@ -772,8 +772,10 @@ void Incidence::setFields( const KCalCore::Incidence::Ptr &incidence )
}
}
- Email org( incidence->organizer()->name(), incidence->organizer()->email() );
- setOrganizer( org );
+ if (incidence->organizer()) {
+ Email org( incidence->organizer()->name(), incidence->organizer()->email() );
+ setOrganizer( org );
+ }
// Attendees:
KCalCore::Attendee::List attendees = incidence->attendees();