From: Joey Hess Date: Fri, 13 Nov 2020 17:34:28 +0000 (-0400) Subject: fix build on windows X-Git-Tag: archive/raspbian/10.20250416-2+rpi1~1^2~102^2~66^2~11 X-Git-Url: https://dgit.raspbian.org/?a=commitdiff_plain;h=ed7afabdb1de31b8b3a8269e882bace98af994b8;p=git-annex.git fix build on windows --- diff --git a/Utility/LockFile/Windows.hs b/Utility/LockFile/Windows.hs index a8a0748434..781f8cfd31 100644 --- a/Utility/LockFile/Windows.hs +++ b/Utility/LockFile/Windows.hs @@ -27,7 +27,7 @@ type LockHandle = HANDLE {- Tries to lock a file with a shared lock, which allows other processes to - also lock it shared. Fails if the file is exclusively locked. -} lockShared :: LockFile -> IO (Maybe LockHandle) -lockShared = openLock fILE_SHARE_READ . fromRawFilePath +lockShared = openLock fILE_SHARE_READ {- Tries to take an exclusive lock on a file. Fails if another process has - a shared or exclusive lock. @@ -36,7 +36,7 @@ lockShared = openLock fILE_SHARE_READ . fromRawFilePath - read or write by any other process. So for advisory locking of a file's - content, a separate LockFile should be used. -} lockExclusive :: LockFile -> IO (Maybe LockHandle) -lockExclusive = openLock fILE_SHARE_NONE . fromRawFilePath +lockExclusive = openLock fILE_SHARE_NONE {- Windows considers just opening a file enough to lock it. This will - create the LockFile if it does not already exist.