git.samba.org
/
jelmer
/
calypso.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
7cedc50
)
Only import lockfile.pidlockfile when needed
author
Guido Günther
<agx@sigxcpu.org>
Mon, 25 Jan 2016 07:01:32 +0000
(08:01 +0100)
committer
Guido Günther
<agx@sigxcpu.org>
Tue, 26 Jan 2016 17:25:13 +0000
(18:25 +0100)
Debian Jessie python-lockfile 0.8 lacks it and a pidlockfile is not
always needed.
calypso.py
patch
|
blob
|
history
diff --git
a/calypso.py
b/calypso.py
index c3c199998006cb19bb1a59c1b610cfbd59787a76..7d8c31b31bac50bdd08e634eb61de3613970a557 100755
(executable)
--- a/
calypso.py
+++ b/
calypso.py
@@
-38,7
+38,6
@@
arguments.
import daemon
import lockfile
-from lockfile import pidlockfile
import logging
import optparse
import os
@@
-149,6
+148,7
@@
if not options.daemon:
context = daemon.DaemonContext()
context.umask = 0o002
if options.pidfile:
+ from lockfile import pidlockfile
# Generate a pidfile where requested
context.pidfile = pidlockfile.PIDLockFile(options.pidfile)
with context: