From: Matt Joiner Date: Sun, 20 Jul 2025 01:41:14 +0000 (+1000) Subject: Count actual webseed data read rather than expected X-Git-Tag: v1.59.0~4 X-Git-Url: http://www.git.stargrave.org/?a=commitdiff_plain;h=dda1d97c6a222e335874b713e6dc36c20a92d816;p=btrtrc.git Count actual webseed data read rather than expected Note they probably never differ at this point but still. --- diff --git a/webseed-peer.go b/webseed-peer.go index b7c7a54f..35fd8ffe 100644 --- a/webseed-peer.go +++ b/webseed-peer.go @@ -284,7 +284,7 @@ func (ws *webseedPeer) readChunks(wr *webseedRequest) (err error) { err = fmt.Errorf("reading chunk: %w", err) return } - ws.peer.doChunkReadStats(int64(chunkLen)) + ws.peer.doChunkReadStats(int64(n)) // TODO: Clean up the parameters for receiveChunk. msg.Piece = buf msg.Index = reqSpec.Index