From 6a1b296ef5d97cccebc1ee9d793a8e874e434373 Mon Sep 17 00:00:00 2001 From: Joey Hess Date: Sun, 3 Aug 2014 16:18:40 -0400 Subject: remove redundant progress meter display code specialRemote handles all meter display, so this is redundant. --- Remote/Helper/Chunked.hs | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/Remote/Helper/Chunked.hs b/Remote/Helper/Chunked.hs index 2e9467b2a..7ad790cb1 100644 --- a/Remote/Helper/Chunked.hs +++ b/Remote/Helper/Chunked.hs @@ -101,10 +101,8 @@ storeChunks u chunkconfig k f p storer checker = case chunkconfig of (UnpaddedChunks chunksize) | isStableKey k -> bracketIO open close (go chunksize) - _ -> showprogress $ storer k (FileContent f) + _ -> storer k (FileContent f) p where - showprogress = metered (Just p) k - open = tryIO $ openBinaryFile f ReadMode close (Right h) = hClose h @@ -113,11 +111,11 @@ storeChunks u chunkconfig k f p storer checker = go _ (Left e) = do warning (show e) return False - go chunksize (Right h) = showprogress $ \meterupdate -> do + go chunksize (Right h) = do let chunkkeys = chunkKeyStream k chunksize (chunkkeys', startpos) <- seekResume h chunkkeys checker b <- liftIO $ L.hGetContents h - gochunks meterupdate startpos chunksize b chunkkeys' + gochunks p startpos chunksize b chunkkeys' gochunks :: MeterUpdate -> BytesProcessed -> ChunkSize -> L.ByteString -> ChunkKeyStream -> Annex Bool gochunks meterupdate startpos chunksize = loop startpos . splitchunk -- cgit v1.2.3