Catch possible crash in Pedigree View.

svn: r8475
This commit is contained in:
Brian Matherly 2007-05-15 11:40:25 +00:00
parent 247e0020ed
commit 26ef497eaa
2 changed files with 4 additions and 1 deletions

View File

@ -1,3 +1,6 @@
2007-05-15 Brian Matherly <brian@gramps-project.org>
* src/DataViews/_PedigreeView.py: Catch possible crash
2007-05-14 Don Allingham <don@gramps-project.org>
* src/DataViews/_PedigreeView.py: catch errors
* src/DataViews/_RelationView.py: catch errors

View File

@ -852,7 +852,7 @@ class PedigreeView(PageView.PersonNavView):
obj = self.dbstate.db.get_object_from_handle(object_handle)
if obj:
mtype = obj.get_mime_type()
if mtype[0:5] == "image":
if mtype and mtype[0:5] == "image":
image = ImgManip.get_thumbnail_path(obj.get_path())
if cairo_available:
pw = PersonBoxWidget_cairo( self.format_helper, lst[i][0], lst[i][3], positions[i][0][3], image);