We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 55bfa41 commit a3cdff3Copy full SHA for a3cdff3
Annex/Transfer.hs
@@ -151,6 +151,11 @@ runTransfer' ignorelock t afile stalldetection retrydecider transferaction =
151
createAnnexDirectory $ P.takeDirectory lck
152
tryLockExclusive (Just mode) lck >>= \case
153
Nothing -> return (Nothing, True)
154
+ -- Since the lock file is removed in cleanup,
155
+ -- there's a race where different processes
156
+ -- may have a deleted and a new version of the same
157
+ -- lock file open. checkSaneLock guards against
158
+ -- that.
159
Just lockhandle -> ifM (checkSaneLock lck lockhandle)
160
( do
161
createtfile
0 commit comments