diff options
author | Milan Crha <mcrha@redhat.com> | 2010-02-25 01:00:27 +0800 |
---|---|---|
committer | Milan Crha <mcrha@redhat.com> | 2010-02-25 01:00:27 +0800 |
commit | 50fb261954dabc9b9421466aa7b8929216f24028 (patch) | |
tree | f0d0b076e498ad3788868dc2d1db9de1d6f21cdb /plugins | |
parent | a0f7dea42b2ba6aa1a18a14745bb1cb96341b375 (diff) | |
download | gsoc2013-evolution-50fb261954dabc9b9421466aa7b8929216f24028.tar gsoc2013-evolution-50fb261954dabc9b9421466aa7b8929216f24028.tar.gz gsoc2013-evolution-50fb261954dabc9b9421466aa7b8929216f24028.tar.bz2 gsoc2013-evolution-50fb261954dabc9b9421466aa7b8929216f24028.tar.lz gsoc2013-evolution-50fb261954dabc9b9421466aa7b8929216f24028.tar.xz gsoc2013-evolution-50fb261954dabc9b9421466aa7b8929216f24028.tar.zst gsoc2013-evolution-50fb261954dabc9b9421466aa7b8929216f24028.zip |
Bug #601551 - [PST] evolution crashed with SIGSEGV
Diffstat (limited to 'plugins')
-rw-r--r-- | plugins/pst-import/pst-importer.c | 14 |
1 files changed, 11 insertions, 3 deletions
diff --git a/plugins/pst-import/pst-importer.c b/plugins/pst-import/pst-importer.c index 9662caca1e..7d2868042a 100644 --- a/plugins/pst-import/pst-importer.c +++ b/plugins/pst-import/pst-importer.c @@ -579,19 +579,19 @@ pst_process_item (PstImporter *m, pst_desc_tree *d_ptr) pst_process_contact (m, item); } - } else if (item->type == PST_TYPE_APPOINTMENT) { + } else if (item->type == PST_TYPE_APPOINTMENT && item->appointment) { if (m->calendar && GPOINTER_TO_INT (g_datalist_get_data (&m->target->data, "pst-do-appt"))) { pst_process_appointment (m, item); } - } else if (item->type == PST_TYPE_TASK) { + } else if (item->type == PST_TYPE_TASK && item->appointment) { if (m->tasks && GPOINTER_TO_INT (g_datalist_get_data (&m->target->data, "pst-do-task"))) { pst_process_task (m, item); } - } else if (item->type == PST_TYPE_JOURNAL) { + } else if (item->type == PST_TYPE_JOURNAL && item->appointment) { if (m->journal && GPOINTER_TO_INT (g_datalist_get_data (&m->target->data, "pst-do-journal"))) { pst_process_journal (m, item); @@ -1283,6 +1283,8 @@ fill_calcomponent (PstImporter *m, pst_item *item, ECalComponent *ec, const gcha a = item->appointment; e = item->email; + g_return_if_fail (item->appointment != NULL); + if (item->create_date) { struct icaltimetype tt; tt = get_ical_date (item->create_date, FALSE); @@ -1432,6 +1434,8 @@ pst_process_appointment (PstImporter *m, pst_item *item) { ECalComponent *ec; + g_return_if_fail (item->appointment != NULL); + ec = e_cal_component_new (); e_cal_component_set_new_vtype (ec, E_CAL_COMPONENT_EVENT); @@ -1452,6 +1456,8 @@ pst_process_task (PstImporter *m, pst_item *item) { ECalComponent *ec; + g_return_if_fail (item->appointment != NULL); + ec = e_cal_component_new (); e_cal_component_set_new_vtype (ec, E_CAL_COMPONENT_TODO); @@ -1474,6 +1480,8 @@ pst_process_journal (PstImporter *m, pst_item *item) { ECalComponent *ec; + g_return_if_fail (item->appointment != NULL); + /*j = item->journal;*/ ec = e_cal_component_new (); e_cal_component_set_new_vtype (ec, E_CAL_COMPONENT_JOURNAL); |