From d93785945bb375d4f6efabda0a3ef5333b940ad2 Mon Sep 17 00:00:00 2001 From: Faik Uygur Date: Thu, 16 Oct 2008 07:27:35 +0000 Subject: [PATCH] finally makes it. Also this was preventing to see the full exception backtrace. --- pisi/api.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/pisi/api.py b/pisi/api.py index a2de9abd..b1897e5b 100644 --- a/pisi/api.py +++ b/pisi/api.py @@ -59,9 +59,8 @@ def locked(func): fcntl.flock(lock, fcntl.LOCK_EX | fcntl.LOCK_NB) try: return func(*__args,**__kw) - except Exception, e: + finally: lock.close() - raise e except IOError: raise pisi.errors.AnotherInstanceError(_("Another instance of PiSi is running. Only one instance is allowed.")) return wrapper