From 34ec344e9d547995b6faee6d07b6648eb0e4e802 Mon Sep 17 00:00:00 2001 From: Thomas Waldmann Date: Sat, 17 Sep 2016 17:19:26 +0200 Subject: [PATCH] trivial code optimization --- borg/archive.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/borg/archive.py b/borg/archive.py index bacf37605..8619fd8f1 100644 --- a/borg/archive.py +++ b/borg/archive.py @@ -642,7 +642,7 @@ Number of files: {0.stats.nfiles}'''.format( # Is it a hard link? if st.st_nlink > 1: source = self.hard_links.get((st.st_ino, st.st_dev)) - if (st.st_ino, st.st_dev) in self.hard_links: + if source is not None: item = self.stat_attrs(st, path) item.update({b'path': safe_path, b'source': source}) self.add_item(item)