From 7d3a5566489b4937be6e763e7b3fe2aa6fc4c5e8 Mon Sep 17 00:00:00 2001 From: "g@localhost.localdomain" Date: Wed, 22 Nov 2006 23:41:48 +0100 Subject: [PATCH] cache_add_hardlink may be given a path instead of a basename --- pysize/core/pysize_global_fs_cache.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pysize/core/pysize_global_fs_cache.py b/pysize/core/pysize_global_fs_cache.py index 006c627..25da88e 100644 --- a/pysize/core/pysize_global_fs_cache.py +++ b/pysize/core/pysize_global_fs_cache.py @@ -43,11 +43,11 @@ def cache_add_dir((dev, ino), size): inodes = DEV_DIR_SIZE.setdefault(dev, {}) inodes[ino] = size -def cache_add_hardlink(dev, ino, dir_ino, basename): +def cache_add_hardlink(dev, ino, dir_ino, path): """Add a hardlink and its location to the cache, and returns True iff the location should be considered as the canonical location. Unlike for the canonical location, a hardlink size is 0.""" - entry = dir_ino, basename + entry = dir_ino, os.path.basename(path) inodes = DEV_HLINK_DNAME.setdefault(dev, {}) cached_entry = inodes.setdefault(ino, entry) return cached_entry == entry -- 2.11.4.GIT