]> git.rkrishnan.org Git - functorrent.git/commit
Handle the `left' parameter for the tracker request.
authorRamakrishnan Muthukrishnan <ram@rkrishnan.org>
Tue, 17 Feb 2015 11:05:00 +0000 (16:35 +0530)
committerRamakrishnan Muthukrishnan <ram@rkrishnan.org>
Tue, 17 Feb 2015 11:05:00 +0000 (16:35 +0530)
commit1f707b2dc36f4b5d9c083c57de71906663f1c313
tree9f930c27730428e18ce347bccfab79f7fe604a3b
parenteaf4079c1d0dc2355a22e57bfc8285bae70abcba
Handle the `left' parameter for the tracker request.

Tracker initial request includes a parameter called `left' to indicate
the size of the file left to be downloaded. When we contact the tracker
initially, we haven't downloaded anything yet. So, the left parameter
should be the length parameter. For now, we handle only single file
torrent files, so we just pick the length param from Metainfo and shove
it in into the tracker http request.
src/Main.hs
src/Tracker.hs