IO exception rework
ghc 7.4 comaplains about use of System.IO.Error to catch exceptions. Ok, use Control.Exception, with variants specialized to only catch IO exceptions.
This commit is contained in:
parent
05f89123e0
commit
146c36ca54
14 changed files with 56 additions and 44 deletions
|
@ -8,7 +8,6 @@
|
|||
module Remote.Bup (remote) where
|
||||
|
||||
import qualified Data.ByteString.Lazy.Char8 as L
|
||||
import System.IO.Error
|
||||
import qualified Data.Map as M
|
||||
import System.Process
|
||||
|
||||
|
@ -200,7 +199,7 @@ getBupUUID :: Git.Repo -> UUID -> Annex (UUID, Git.Repo)
|
|||
getBupUUID r u
|
||||
| Git.repoIsUrl r = return (u, r)
|
||||
| otherwise = liftIO $ do
|
||||
ret <- try $ Git.Config.read r
|
||||
ret <- tryIO $ Git.Config.read r
|
||||
case ret of
|
||||
Right r' -> return (toUUID $ Git.Config.get "annex.uuid" "" r', r')
|
||||
Left _ -> return (NoUUID, r)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue