[Nym3-commit] r400 - in trunk: . nymbaron/Client

laurent at conuropsis.org laurent at conuropsis.org
Mon Nov 14 21:38:50 CET 2005


Author: laurent
Date: 2005-11-14 21:38:49 +0100 (Mon, 14 Nov 2005)
New Revision: 400

Modified:
   trunk/TODO
   trunk/nymbaron/Client/Account.py
Log:
Don't fail with an "already locked" exception, just wait.


Modified: trunk/TODO
===================================================================
--- trunk/TODO	2005-11-14 10:05:57 UTC (rev 399)
+++ trunk/TODO	2005-11-14 20:38:49 UTC (rev 400)
@@ -8,12 +8,12 @@
         D Deferred
         X Abandoned
 
- * don't fail miserably when another instance holds a lock, instead simply
-   wait for it a few times [client]
  * be able to cope with base64 encoded as well as raw binary input
    flawlessly for nymbaron -m [server]
  * display the username in list-accounts [client]
  * let the user set the domainname of the account when known.
+ . don't fail miserably when another instance holds a lock, instead simply
+   wait for it a few times [client]
  o clarify the "localpart" thing in nymbarond(8) [doc]
  o catch Ctrl-C interruption on passphrase input [client]
  o check every command that ask for user input can be interrupted cleanly

Modified: trunk/nymbaron/Client/Account.py
===================================================================
--- trunk/nymbaron/Client/Account.py	2005-11-14 10:05:57 UTC (rev 399)
+++ trunk/nymbaron/Client/Account.py	2005-11-14 20:38:49 UTC (rev 400)
@@ -66,7 +66,7 @@
     def _lock(self):
         """Lock the tagmap file"""
         self.lock = mixminion.Common.Lockfile(self.filename + '.lck')
-        self.lock.acquire()
+        self.lock.acquire(blocking = 1)
 
     def _release(self):
         self.lock.release()
@@ -286,7 +286,7 @@
 	"""Locks the user. For well behaved functions."""
 	self.lock = mixminion.Common.Lockfile(self.config.path + os.sep + 
 		    self['idTag'] + '.lck')
-	self.lock.acquire()
+	self.lock.acquire(blocking = 1)
 
     def _release(self):
 	"""Releases the lock"""



More information about the Nym3-commit mailing list