summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--lib/KeyRing/BuildKeyDB.hs9
1 files changed, 5 insertions, 4 deletions
diff --git a/lib/KeyRing/BuildKeyDB.hs b/lib/KeyRing/BuildKeyDB.hs
index bae2538..ad47ed0 100644
--- a/lib/KeyRing/BuildKeyDB.hs
+++ b/lib/KeyRing/BuildKeyDB.hs
@@ -40,6 +40,7 @@ import qualified Data.ByteString.Lazy as L (ByteString, concat, empty,
40 fromChunks, hGetContents, 40 fromChunks, hGetContents,
41 null, readFile, toChunks) 41 null, readFile, toChunks)
42import Data.Char 42import Data.Char
43import Data.Function
43import Data.List 44import Data.List
44import qualified Data.Map as Map 45import qualified Data.Map as Map
45import Data.Maybe 46import Data.Maybe
@@ -302,13 +303,13 @@ readPacketsFromFile ctx fname = do
302 -- warn $ fname ++ ": reading..." 303 -- warn $ fname ++ ": reading..."
303 input <- readInputFileL ctx fname 304 input <- readInputFileL ctx fname
304#if MIN_VERSION_binary(0,7,0) 305#if MIN_VERSION_binary(0,7,0)
305 return $ 306 return $ Message $ flip fix input $ \again some ->
306 case decodeOrFail input of 307 case decodeOrFail some of
307 Right (_,_,msg ) -> msg 308 Right (more,_,msg ) -> msg : again more
308 Left (_,_,_) -> 309 Left (_,_,_) ->
309 -- FIXME 310 -- FIXME
310 -- trace (fname++": read fail") $ 311 -- trace (fname++": read fail") $
311 Message [] 312 []
312#else 313#else
313 return $ decode input 314 return $ decode input
314#endif 315#endif