summaryrefslogtreecommitdiff
path: root/Assistant/Threads
diff options
context:
space:
mode:
authorGravatar Joey Hess <joey@kitenet.net>2013-12-01 15:37:51 -0400
committerGravatar Joey Hess <joey@kitenet.net>2013-12-01 15:37:51 -0400
commit65eaac291552cbe155c58371139b66ab2ca572be (patch)
tree97bc448297f2fc4b74413afd038221996de8976b /Assistant/Threads
parent0b24863a852497b669d0a6f18b32cef014131d4b (diff)
avoid repeatedly searching path to make batch command when running transferkeys
Diffstat (limited to 'Assistant/Threads')
-rw-r--r--Assistant/Threads/Transferrer.hs4
1 files changed, 3 insertions, 1 deletions
diff --git a/Assistant/Threads/Transferrer.hs b/Assistant/Threads/Transferrer.hs
index 0bc419e15..53d8a578c 100644
--- a/Assistant/Threads/Transferrer.hs
+++ b/Assistant/Threads/Transferrer.hs
@@ -12,12 +12,14 @@ import Assistant.TransferQueue
import Assistant.TransferSlots
import Logs.Transfer
import Config.Files
+import Utility.Batch
{- Dispatches transfers from the queue. -}
transfererThread :: NamedThread
transfererThread = namedThread "Transferrer" $ do
program <- liftIO readProgramFile
- forever $ inTransferSlot program $
+ batchmaker <- liftIO getBatchCommandMaker
+ forever $ inTransferSlot program batchmaker $
maybe (return Nothing) (uncurry genTransfer)
=<< getNextTransfer notrunning
where