From: Joey Hess Date: Tue, 17 Nov 2020 15:58:45 +0000 (-0400) Subject: fix build on windows X-Git-Tag: archive/raspbian/10.20250416-2+rpi1~1^2~102^2~64 X-Git-Url: https://dgit.raspbian.org/?a=commitdiff_plain;h=bce8865824e48e57fe5de08d4d2a909857ec942b;p=git-annex.git fix build on windows --- diff --git a/Utility/Daemon.hs b/Utility/Daemon.hs index 2e1a9baa8f..683a59263e 100644 --- a/Utility/Daemon.hs +++ b/Utility/Daemon.hs @@ -176,14 +176,14 @@ stopDaemon pidfile = go =<< checkDaemon pidfile - when eg, restarting the daemon. -} #ifdef mingw32_HOST_OS -winLockFile :: PID -> FilePath -> IO FilePath +winLockFile :: PID -> FilePath -> IO RawFilePath winLockFile pid pidfile = do cleanstale - return $ prefix ++ show pid ++ suffix + return $ toRawFilePath $ prefix ++ show pid ++ suffix where prefix = pidfile ++ "." suffix = ".lck" cleanstale = mapM_ (void . tryIO . removeFile) =<< - (filter iswinlockfile <$> dirContents (parentDir pidfile)) + (filter iswinlockfile <$> dirContents (fromRawFilePath (parentDir (toRawFilePath pidfile)))) iswinlockfile f = suffix `isSuffixOf` f && prefix `isPrefixOf` f #endif