Only call now() once inside any event.lock() call

This commit is contained in:
Raphael Michel
2016-08-29 22:32:15 +02:00
parent 65c16bdc58
commit c30ff5e657
7 changed files with 62 additions and 56 deletions

View File

@@ -19,6 +19,7 @@ class LockManager:
def __enter__(self):
lock_event(self.event)
return now()
def __exit__(self, exc_type, exc_val, exc_tb):
release_event(self.event)