Fixed locked() for noninteractive UIs

From: "Mark A. Hershberger"

https://bugs.launchpad.net/ubuntu/+source/offlineimap/+bug/96710

the locked() method isn't implemented for non-interactive UIs, so
exceptions are thrown on cron jobs.  Ubuntu's new apport catches these
and ? well, you get the idea.

patch provided.
This commit is contained in:
John Goerzen 2007-10-10 00:12:22 +01:00
parent 3305d8cd4d
commit cdccfd83b1
1 changed files with 3 additions and 0 deletions

View File

@ -43,6 +43,9 @@ class Basic(UIBase):
time.sleep(sleepsecs)
return 0
def locked(s):
s.warn("Another OfflineIMAP is running with the same metadatadir; exiting.")
class Quiet(Basic):
def __init__(s, config, verbose = -1):
Basic.__init__(s, config, verbose)