提交 116d1a8a 编写于 作者: J Julien Cristau

clean_suites: fix clean_byhash when Dinstall::SuiteSuffix is set

Signed-off-by: NJulien Cristau <jcristau@debian.org>
上级 b53415a5
......@@ -386,6 +386,9 @@ SELECT f.id, f.fingerprint FROM fingerprint f
################################################################################
def clean_byhash(now_date, session):
cnf = Config()
suite_suffix = cnf.find("Dinstall::SuiteSuffix", "")
Logger.log(["Cleaning out unused by-hash files..."])
q = session.execute("""
......@@ -399,7 +402,7 @@ def clean_byhash(now_date, session):
if not Options["No-Action"]:
for base, suite, path in q:
filename = os.path.join(base, 'dists', suite, path)
filename = os.path.join(base, 'dists', suite, suite_suffix, path)
try:
os.unlink(filename)
except OSError as exc:
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册