[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
[minion-cvs] Make file locking work crossplatform; clean up interface
Update of /home/minion/cvsroot/src/minion/lib/mixminion/server
In directory moria.mit.edu:/tmp/cvs-serv12239/lib/mixminion/server
Modified Files:
ServerMain.py
Log Message:
Make file locking work crossplatform; clean up interface
Index: ServerMain.py
===================================================================
RCS file: /home/minion/cvsroot/src/minion/lib/mixminion/server/ServerMain.py,v
retrieving revision 1.85
retrieving revision 1.86
diff -u -d -r1.85 -r1.86
--- ServerMain.py 13 Jul 2003 03:45:35 -0000 1.85
+++ ServerMain.py 15 Jul 2003 15:30:56 -0000 1.86
@@ -63,8 +63,8 @@
from bisect import insort
from mixminion.Common import LOG, LogStream, MixError, MixFatalError,\
UIError, ceilDiv, createPrivateDir, formatBase64, formatTime, \
- installSIGCHLDHandler, Lockfile, readFile, secureDelete, tryUnlink, \
- waitForChildren, writeFile
+ installSIGCHLDHandler, Lockfile, LockfileLocked, readFile, secureDelete, \
+ tryUnlink, waitForChildren, writeFile
# Version number for server home-directory.
#
@@ -622,7 +622,7 @@
self.lockFile = Lockfile(os.path.join(homeDir, "lock"))
try:
self.lockFile.acquire()
- except IOError:
+ except LockfileLocked:
raise MixFatalError("Another server seems to be running.")
# The pid file.