From fb224635a5011b475c85243f5f7a22335d5ec605 Mon Sep 17 00:00:00 2001 From: Dmitry Zuikov Date: Sun, 26 Feb 2023 14:05:27 +0300 Subject: [PATCH] minor-fix --- hbs2-peer/app/PeerTypes.hs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/hbs2-peer/app/PeerTypes.hs b/hbs2-peer/app/PeerTypes.hs index ae244b2b..07c64e78 100644 --- a/hbs2-peer/app/PeerTypes.hs +++ b/hbs2-peer/app/PeerTypes.hs @@ -289,7 +289,10 @@ addDownload h = do wip <- asks (view blockWip) liftIO do - atomically $ writeTQueue q h + atomically $ do + modifyTVar tinq $ HashMap.insert h () + writeTQueue q h + Cache.insert wip h () -- | False -> do -- not hasSize -> do