]> Sergey Matveev's repositories - btrtrc.git/commit
Rewrite file.bytesLeft
authorMatt Joiner <anacrolix@gmail.com>
Tue, 24 Mar 2020 01:15:35 +0000 (12:15 +1100)
committerMatt Joiner <anacrolix@gmail.com>
Tue, 24 Mar 2020 01:15:35 +0000 (12:15 +1100)
commit364d3dd208311430e0ab5173d4d6328b9e6330b6
tree53553dfe66370284f99150905f0b435b92d64c38
parent4be8b12207fc63d289ed47011747231dd4a7e1ec
Rewrite file.bytesLeft

Avoids iteration, and should handle files that are entirely inside a single piece, as well as zero-sized at the beginning of a torrent. Should fix #387.
file.go
file_test.go