summaryrefslogtreecommitdiff
path: root/Command/Whereis.hs
diff options
context:
space:
mode:
authorGravatar Joey Hess <joeyh@joeyh.name>2016-09-09 15:49:44 -0400
committerGravatar Joey Hess <joeyh@joeyh.name>2016-09-09 15:51:34 -0400
commitd1f722e3b0b74a9d9a2e35ac1f47dbca9f7cf606 (patch)
tree74314a3747d4a0456135bf38b2e1115b5a3f64b9 /Command/Whereis.hs
parent2408f5c6084aa04a09b36edcd264ce6bc7177c93 (diff)
better locking for json with -J
Avoid threads emitting json at the same time and scrambling, which was still possible even with the buffering, just less likely. Converted json IO actions to JSONChunk data too.
Diffstat (limited to 'Command/Whereis.hs')
-rw-r--r--Command/Whereis.hs5
1 files changed, 2 insertions, 3 deletions
diff --git a/Command/Whereis.hs b/Command/Whereis.hs
index 3a21e0a3b..bcc11aaf7 100644
--- a/Command/Whereis.hs
+++ b/Command/Whereis.hs
@@ -105,7 +105,6 @@ showRemoteUrls :: M.Map UUID Remote -> (UUID, [URLString]) -> Annex ()
showRemoteUrls remotemap (uu, us)
| null us = noop
| otherwise = case M.lookup uu remotemap of
- Just r -> do
- let ls = unlines $ map (\u -> name r ++ ": " ++ u) us
- outputMessage noop ('\n' : indent ls ++ "\n")
+ Just r -> showLongNote $
+ unlines $ map (\u -> name r ++ ": " ++ u) us
Nothing -> noop