From 381c1f7634e20a2faa0b15255870f9dbf745f230 Mon Sep 17 00:00:00 2001 From: Joey Hess Date: Sun, 4 Aug 2013 13:12:18 -0400 Subject: squash compiler warnings on Windows --- Remote/Git.hs | 10 +++++++--- Remote/Helper/Hooks.hs | 2 ++ 2 files changed, 9 insertions(+), 3 deletions(-) (limited to 'Remote') diff --git a/Remote/Git.hs b/Remote/Git.hs index c9cebfb14..e269b9ad8 100644 --- a/Remote/Git.hs +++ b/Remote/Git.hs @@ -17,7 +17,6 @@ import qualified Data.Map as M import Control.Exception.Extensible import Common.Annex -import Utility.CopyFile import Utility.Rsync import Remote.Helper.Ssh import Annex.Ssh @@ -44,6 +43,9 @@ import Types.Key import qualified Fields import Logs.Location import Utility.Metered +#ifndef mingw32_HOST_OS +import Utility.CopyFile +#endif import Control.Concurrent import Control.Concurrent.MSampleVar @@ -360,8 +362,8 @@ copyFromRemote' r key file dest bracketIO noop (const $ tryIO $ killThread tid) (const $ a feeder) copyFromRemoteCheap :: Remote -> Key -> FilePath -> Annex Bool -copyFromRemoteCheap r key file #ifndef mingw32_HOST_OS +copyFromRemoteCheap r key file | not $ Git.repoIsUrl (repo r) = guardUsable (repo r) False $ do loc <- liftIO $ gitAnnexLocation key (repo r) $ fromJust $ remoteGitConfig $ gitconfig r @@ -371,8 +373,10 @@ copyFromRemoteCheap r key file ( copyFromRemote' r key Nothing file , return False ) -#endif | otherwise = return False +#else +copyFromRemoteCheap _ _ _ = return False +#endif {- Tries to copy a key's content to a remote's annex. -} copyToRemote :: Remote -> Key -> AssociatedFile -> MeterUpdate -> Annex Bool diff --git a/Remote/Helper/Hooks.hs b/Remote/Helper/Hooks.hs index dfc543d0a..96081b024 100644 --- a/Remote/Helper/Hooks.hs +++ b/Remote/Helper/Hooks.hs @@ -15,7 +15,9 @@ import Common.Annex import Types.Remote import qualified Annex import Annex.LockPool +#ifndef mingw32_HOST_OS import Annex.Perms +#endif {- Modifies a remote's access functions to first run the - annex-start-command hook, and trigger annex-stop-command on shutdown. -- cgit v1.2.3