From: Mark Hymers Date: Wed, 27 Jul 2011 20:02:21 +0000 (+0100) Subject: Remove Dinstall::LockFile X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=af72c901d49515105812b8ef46ce98b55d4072ba;p=dak Remove Dinstall::LockFile Signed-off-by: Mark Hymers --- diff --git a/dak/process_upload.py b/dak/process_upload.py index 4e734da4..84186c57 100755 --- a/dak/process_upload.py +++ b/dak/process_upload.py @@ -455,7 +455,7 @@ def main(): # Obtain lock if not in no-action mode and initialize the log if not Options["No-Action"]: - lock_fd = os.open(cnf["Dinstall::LockFile"], os.O_RDWR | os.O_CREAT) + lock_fd = os.open(os.path.join(cnf["Dir::Lock"], 'dinstall.lock'), os.O_RDWR | os.O_CREAT) try: fcntl.lockf(lock_fd, fcntl.LOCK_EX | fcntl.LOCK_NB) except IOError, e: diff --git a/dak/update_db.py b/dak/update_db.py index cd34e63e..2e1c0caa 100755 --- a/dak/update_db.py +++ b/dak/update_db.py @@ -198,7 +198,7 @@ Updates dak's database schema to the lastest version. You should disable crontab self.usage(exit_code=1) try: - lock_fd = os.open(cnf["Dinstall::LockFile"], os.O_RDWR | os.O_CREAT) + lock_fd = os.open(os.path.join(cnf["Dir::Lock"], 'dinstall.lock'), os.O_RDWR | os.O_CREAT) fcntl.lockf(lock_fd, fcntl.LOCK_EX | fcntl.LOCK_NB) except IOError, e: if errno.errorcode[e.errno] == 'EACCES' or errno.errorcode[e.errno] == 'EAGAIN':