From: Torsten Werner Date: Wed, 27 Jul 2011 11:05:19 +0000 (+0200) Subject: commit more often in clean-suites X-Git-Url: https://git.decadent.org.uk/gitweb/?a=commitdiff_plain;h=ca2ce4c3ffba031f5ddb84c225d474c910504ac0;p=dak.git commit more often in clean-suites ... to avoid database leaks in case of exceptions Signed-off-by: Torsten Werner --- diff --git a/dak/clean_suites.py b/dak/clean_suites.py index 5e41d372..b0711acb 100755 --- a/dak/clean_suites.py +++ b/dak/clean_suites.py @@ -298,13 +298,11 @@ SELECT s.id, f.filename FROM source s, files f if not Options["No-Action"]: session.delete(pf) + session.commit() else: utils.fubar("%s is neither symlink nor file?!" % (filename)) - if not Options["No-Action"]: - session.commit() - if count > 0: Logger.log(["total", count, utils.size_type(size)]) print "Cleaned %d files, %s." % (count, utils.size_type(size))