From 657fad53789cbd37076b819eae0b9f91fd92efac Mon Sep 17 00:00:00 2001 From: Joey Hess Date: Mon, 3 Aug 2015 15:54:29 -0400 Subject: windows build warning fixes --- Annex/Content.hs | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'Annex') diff --git a/Annex/Content.hs b/Annex/Content.hs index 1a2ed06c1..077407071 100644 --- a/Annex/Content.hs +++ b/Annex/Content.hs @@ -176,8 +176,6 @@ lockContent key a = do (const $ a $ ContentLock key ) where alreadylocked = error "content is locked" - failedtolock e = error $ "failed to lock content: " ++ show e - trylock locker = locker `catchIO` failedtolock cleanuplockfile lockfile = modifyContent lockfile $ void $ liftIO $ tryIO $ nukeFile lockfile @@ -197,6 +195,9 @@ lockContent key a = do unlock mlockfile lck = do maybe noop cleanuplockfile mlockfile liftIO $ dropLock lck + + failedtolock e = error $ "failed to lock content: " ++ show e + trylock locker = locker `catchIO` failedtolock #else lock _ (Just lockfile) = do modifyContent lockfile $ -- cgit v1.2.3