From b5260704df996ada8bb6724792f4cb74574c9a72 Mon Sep 17 00:00:00 2001 From: prculley Date: Wed, 13 Jul 2016 10:56:47 -0500 Subject: [PATCH 1/2] bug 9579 Gedcom import of FTM file with OCCU record crashes import --- gramps/plugins/lib/libgedcom.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gramps/plugins/lib/libgedcom.py b/gramps/plugins/lib/libgedcom.py index 6a9679686..911de1388 100755 --- a/gramps/plugins/lib/libgedcom.py +++ b/gramps/plugins/lib/libgedcom.py @@ -5448,8 +5448,8 @@ class GedcomParser(UpdateCallback): state.msg += sub_state.msg if sub_state.pf: # if we found local PLAC:FORM state.pf = sub_state.pf # save to override global value - # merge notes etc into place - state.place.merge(sub_state.place) + # merge notes etc into place + state.place.merge(sub_state.place) def __event_place_note(self, line, state): """ From 2eed3c4ab6831c76c6026a82311904d340d46e13 Mon Sep 17 00:00:00 2001 From: prculley Date: Thu, 14 Jul 2016 10:47:01 -0500 Subject: [PATCH 2/2] Fix for either valid or invalid FTM Gedcom --- gramps/plugins/lib/libgedcom.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/gramps/plugins/lib/libgedcom.py b/gramps/plugins/lib/libgedcom.py index 911de1388..ec4bfa1e0 100755 --- a/gramps/plugins/lib/libgedcom.py +++ b/gramps/plugins/lib/libgedcom.py @@ -5417,8 +5417,9 @@ class GedcomParser(UpdateCallback): @type state: CurrentState """ - if self.is_ftw and state.event.type in FTW_BAD_PLACE: - state.event.set_description(line.data) + if self.is_ftw and (state.event.type in FTW_BAD_PLACE) \ + and not state.event.get_description(): + state.event.set_description(line.data) else: title = line.data place = state.place