Commit c0f138db by Michael DeHaan

Merge pull request #2927 from bcoca/solaris_lock

changed lockfile to be opened in write mode
parents d29d142a 8dd72d28
......@@ -68,12 +68,9 @@ def log_lockfile():
tempdir = tempfile.gettempdir()
uid = os.getuid()
path = os.path.join(tempdir, ".ansible-lock.%s" % uid)
if not os.path.exists(path):
fh = open(path, 'w')
fh.close()
return path
LOG_LOCK = open(log_lockfile(), 'r')
LOG_LOCK = open(log_lockfile(), 'w')
def log_flock():
fcntl.flock(LOG_LOCK, fcntl.LOCK_EX)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment