summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/Network/BitTorrent/Exchange/Protocol.hs1
-rw-r--r--src/Network/BitTorrent/Sessions/Types.lhs3
-rw-r--r--src/Network/BitTorrent/Tracker/HTTP.hs4
-rw-r--r--src/Network/BitTorrent/Tracker/Protocol.hs2
-rw-r--r--tests/Main.hs5
5 files changed, 5 insertions, 10 deletions
diff --git a/src/Network/BitTorrent/Exchange/Protocol.hs b/src/Network/BitTorrent/Exchange/Protocol.hs
index 3b2472da..8286ae7d 100644
--- a/src/Network/BitTorrent/Exchange/Protocol.hs
+++ b/src/Network/BitTorrent/Exchange/Protocol.hs
@@ -64,7 +64,6 @@ import Data.ByteString (ByteString)
64import qualified Data.ByteString as B 64import qualified Data.ByteString as B
65import qualified Data.ByteString.Char8 as BC 65import qualified Data.ByteString.Char8 as BC
66import qualified Data.ByteString.Lazy as Lazy 66import qualified Data.ByteString.Lazy as Lazy
67import Data.Char
68import Data.Default 67import Data.Default
69import Data.List as L 68import Data.List as L
70import Data.Word 69import Data.Word
diff --git a/src/Network/BitTorrent/Sessions/Types.lhs b/src/Network/BitTorrent/Sessions/Types.lhs
index e62e362f..3dde1853 100644
--- a/src/Network/BitTorrent/Sessions/Types.lhs
+++ b/src/Network/BitTorrent/Sessions/Types.lhs
@@ -19,7 +19,8 @@
19> 19>
20> , Progress (..) 20> , Progress (..)
21> , left, uploaded, downloaded 21> , left, uploaded, downloaded
22> , startProgress, enqueuedProgress 22> , startProgress
23> , enqueuedProgress, uploadedProgress, dequeuedProgress
23> 24>
24> , ClientSession (..) 25> , ClientSession (..)
25> 26>
diff --git a/src/Network/BitTorrent/Tracker/HTTP.hs b/src/Network/BitTorrent/Tracker/HTTP.hs
index f781b847..4fef5e56 100644
--- a/src/Network/BitTorrent/Tracker/HTTP.hs
+++ b/src/Network/BitTorrent/Tracker/HTTP.hs
@@ -15,7 +15,7 @@
15-- 15--
16module Network.BitTorrent.Tracker.HTTP 16module Network.BitTorrent.Tracker.HTTP
17 ( askTracker, leaveTracker 17 ( askTracker, leaveTracker
18 , scrapeURL 18 , scrapeURL, scrape, scrapeOne
19 ) where 19 ) where
20 20
21import Control.Applicative 21import Control.Applicative
@@ -30,7 +30,7 @@ import Data.URLEncoded as URL
30import Network.URI 30import Network.URI
31import Network.HTTP 31import Network.HTTP
32 32
33import Data.Torrent.Metainfo 33import Data.Torrent.Metainfo hiding (announce)
34import Network.BitTorrent.Tracker.Protocol 34import Network.BitTorrent.Tracker.Protocol
35 35
36{----------------------------------------------------------------------- 36{-----------------------------------------------------------------------
diff --git a/src/Network/BitTorrent/Tracker/Protocol.hs b/src/Network/BitTorrent/Tracker/Protocol.hs
index c468656f..4e1262ed 100644
--- a/src/Network/BitTorrent/Tracker/Protocol.hs
+++ b/src/Network/BitTorrent/Tracker/Protocol.hs
@@ -261,7 +261,7 @@ instance Serialize AnnounceQuery where
261 261
262 ev <- getEvent 262 ev <- getEvent
263 ip <- getWord32be 263 ip <- getWord32be
264 key <- getWord32be -- TODO 264-- key <- getWord32be -- TODO
265 want <- getWord32be 265 want <- getWord32be
266 266
267 port <- get 267 port <- get
diff --git a/tests/Main.hs b/tests/Main.hs
index a968c487..fb69565d 100644
--- a/tests/Main.hs
+++ b/tests/Main.hs
@@ -52,11 +52,6 @@ prop_properBEncode _ expected = actual == Right expected
52 where 52 where
53 actual = decoded $ Lazy.toStrict $ encoded expected 53 actual = decoded $ Lazy.toStrict $ encoded expected
54 54
55prop_properJSON :: (FromJSON a, ToJSON a) => Eq a => T a -> a -> Bool
56prop_properJSON _ expected = actual == Just expected
57 where
58 actual = JSON.decode $ JSON.encode expected
59
60instance Arbitrary URI where 55instance Arbitrary URI where
61 arbitrary = pure $ fromJust 56 arbitrary = pure $ fromJust
62 $ parseURI "http://exsample.com:80/123365_asd" 57 $ parseURI "http://exsample.com:80/123365_asd"