unlink duplicates

This commit is contained in:
j 2019-01-12 23:40:19 +05:30
parent 56df24baad
commit 80b3ff5b91

View file

@ -151,6 +151,9 @@ def run_scan():
f2 = os.path.join(prefix, f)
if f1 != f2 and os.path.exists(f1) and os.path.exists(f2):
logger.debug('"%s" vs "%s"', f1, f2)
os.chmod(f2, stat.S_IWRITE)
os.unlink(f2)
continue
else:
ids.add(id)