summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGravatar Joey Hess <joeyh@joeyh.name>2014-12-17 14:54:54 -0400
committerGravatar Joey Hess <joeyh@joeyh.name>2014-12-17 14:54:54 -0400
commitdc973c549e28004252b309e603b944b51302a2d6 (patch)
treec12afcc9c7dbae0dffa7a2a50fa110e3cca942f9
parent72706ba1e4161cbff72bc4fd2a18f303197670be (diff)
make checkkey always fail for torrents
See comment.
-rw-r--r--Remote/BitTorrent.hs10
1 files changed, 4 insertions, 6 deletions
diff --git a/Remote/BitTorrent.hs b/Remote/BitTorrent.hs
index c1190a562..902af1079 100644
--- a/Remote/BitTorrent.hs
+++ b/Remote/BitTorrent.hs
@@ -102,14 +102,12 @@ dropKey k = do
mapM_ (setUrlMissing bitTorrentUUID k) =<< getBitTorrentUrls k
return True
-{- This is a very poor check, but checking if a torrent has enough seeders
- - with all the pieces etc is quite hard.. and even if implemented, it
- - tells us nothing about the later state of the torrent.
- -
- - This is why this remote needs to default to untrusted!
+{- We punt and don't try to check if a torrent has enough seeders
+ - with all the pieces etc. That would be quite hard.. and even if
+ - implemented, it tells us nothing about the later state of the torrent.
-}
checkKey :: Key -> Annex Bool
-checkKey key = not . null <$> getBitTorrentUrls key
+checkKey key = error "cannot reliably check torrent status"
-- Makes this remote UnTrusted, unless it already has a trust set.
defaultUnTrusted :: Annex ()