From: Matt Joiner Date: Fri, 29 Oct 2021 00:52:28 +0000 (+1100) Subject: Fix unnecessary modification of Torrent.CancelPieces API X-Git-Tag: v1.35.0~11 X-Git-Url: http://www.git.stargrave.org/?a=commitdiff_plain;h=2c70c23ac4cb1e59fde75c3314682ba09d88f7da;p=btrtrc.git Fix unnecessary modification of Torrent.CancelPieces API https://github.com/anacrolix/torrent/issues/681 --- diff --git a/t.go b/t.go index 78c500dc..a7f98892 100644 --- a/t.go +++ b/t.go @@ -190,7 +190,7 @@ func (t *Torrent) downloadPiecesLocked(begin, end pieceIndex) { } } -func (t *Torrent) CancelPieces(begin, end pieceIndex, reason string) { +func (t *Torrent) CancelPieces(begin, end pieceIndex) { t.cl.lock() t.cancelPiecesLocked(begin, end, "Torrent.CancelPieces") t.cl.unlock()