From 63bca9b3472a393c7ac5625f6b09d53ca9ab17fd Mon Sep 17 00:00:00 2001 From: Joey Hess Date: Tue, 12 May 2015 19:42:09 -0400 Subject: don't clean up transfer lock file when retrying transfer This affected callers that used forwardRetry; if the 1st attempt failed it would clean up the transfer lock before retrying. --- Annex/Transfer.hs | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) (limited to 'Annex') diff --git a/Annex/Transfer.hs b/Annex/Transfer.hs index 14a888620..d8f19eb8d 100644 --- a/Annex/Transfer.hs +++ b/Annex/Transfer.hs @@ -74,10 +74,8 @@ runTransfer' ignorelock t file shouldretry transferobserver transferaction = do showNote "transfer already in progress" return False else do - ok <- retry info metervar $ bracketIO - (return lck) - (cleanup tfile) - (const $ transferaction meter) + ok <- retry info metervar $ transferaction meter + liftIO $ cleanup tfile lck transferobserver ok t info return ok where -- cgit v1.2.3