1
0
Fork 0
mirror of https://github.com/borgbackup/borg.git synced 2024-12-25 09:19:31 +00:00

trivial code optimization

This commit is contained in:
Thomas Waldmann 2016-09-17 17:19:26 +02:00
parent b3fac01683
commit 34ec344e9d

View file

@ -642,7 +642,7 @@ def process_file(self, path, st, cache, ignore_inode=False):
# 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)