fix lockFileShared to actually create lock file
This was a bug, but it was only used for ssh locks and by the hook special remote locking. At least in the case of ssh locks, the lock files happened to already exist before this tried to use them, so the bug didn't cause anything to break.
This commit is contained in:
parent
bf3133ebb0
commit
0a4d301051
1 changed files with 1 additions and 1 deletions
|
@ -36,7 +36,7 @@ lockFileShared file = go =<< fromLockPool file
|
|||
#ifndef mingw32_HOST_OS
|
||||
mode <- annexFileMode
|
||||
lockhandle <- liftIO $ noUmask mode $
|
||||
openFd file ReadOnly (Just mode) defaultFileFlags
|
||||
openFd file ReadWrite (Just mode) defaultFileFlags
|
||||
liftIO $ setFdOption lockhandle CloseOnExec True
|
||||
liftIO $ waitToSetLock lockhandle (ReadLock, AbsoluteSeek, 0, 0)
|
||||
#else
|
||||
|
|
Loading…
Add table
Reference in a new issue