Commit 11d7d400 authored by Kai Willadsen's avatar Kai Willadsen

Avoid calling basename on None paths in tree (closes bgo#654847)

This is defensive code; we shouldn't ever really have empty paths being
traversed in this update, but filesystems are wacky sometimes.
parent 963cd3a4
......@@ -1069,12 +1069,12 @@ class DirDiff(melddoc.MeldDoc, gnomeglade.Component):
for component in changed:
child = model.iter_children( it )
while child:
name = os.path.basename(model.value_path(child, pane))
if component == name : # found it
child_path = model.value_path(child, pane)
# Found the changed path
if child_path and component == os.path.basename(child_path):
it = child
child = self.model.iter_next( child ) # next
child = self.model.iter_next(child)
if not it:
# save if found and unique
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment