diff options
author | 2012-09-06 14:56:04 -0400 | |
---|---|---|
committer | 2012-09-06 14:56:04 -0400 | |
commit | a00f1d26bc3f121e49ee3f6ff5f46d7b330161ff (patch) | |
tree | 1951e9ca7e482fc67f9c232b0fb22680ee19f5a0 /Assistant/Threads/TransferScanner.hs | |
parent | d11ded822cf68d4f33a886e0f97f95a3781e0dc1 (diff) |
display errors when any named thread crashes
Diffstat (limited to 'Assistant/Threads/TransferScanner.hs')
-rw-r--r-- | Assistant/Threads/TransferScanner.hs | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/Assistant/Threads/TransferScanner.hs b/Assistant/Threads/TransferScanner.hs index 87af3567e..ecb9021f0 100644 --- a/Assistant/Threads/TransferScanner.hs +++ b/Assistant/Threads/TransferScanner.hs @@ -31,11 +31,12 @@ thisThread = "TransferScanner" {- This thread waits until a remote needs to be scanned, to find transfers - that need to be made, to keep data in sync. -} -transferScannerThread :: ThreadState -> DaemonStatusHandle -> ScanRemoteMap -> TransferQueue -> IO () -transferScannerThread st dstatus scanremotes transferqueue = do +transferScannerThread :: ThreadState -> DaemonStatusHandle -> ScanRemoteMap -> TransferQueue -> NamedThread +transferScannerThread st dstatus scanremotes transferqueue = thread $ do startupScan go S.empty where + thread = NamedThread thisThread go scanned = do threadDelaySeconds (Seconds 2) (rs, infos) <- unzip <$> getScanRemote scanremotes |