From: Matt Joiner Date: Sun, 18 Feb 2024 01:59:59 +0000 (+1100) Subject: Disable writeChunk perf timer X-Git-Tag: v1.54.1^2~2 X-Git-Url: http://www.git.stargrave.org/?a=commitdiff_plain;h=ab7fefb8b86d8c997e67aab85e817285f956a5c7;p=btrtrc.git Disable writeChunk perf timer --- diff --git a/torrent.go b/torrent.go index 2643dd6a..63bfe744 100644 --- a/torrent.go +++ b/torrent.go @@ -24,7 +24,6 @@ import ( . "github.com/anacrolix/generics" g "github.com/anacrolix/generics" "github.com/anacrolix/log" - "github.com/anacrolix/missinggo/perf" "github.com/anacrolix/missinggo/slices" "github.com/anacrolix/missinggo/v2" "github.com/anacrolix/missinggo/v2/bitmap" @@ -949,7 +948,7 @@ func (t *Torrent) offsetRequest(off int64) (req Request, ok bool) { } func (t *Torrent) writeChunk(piece int, begin int64, data []byte) (err error) { - defer perf.ScopeTimerErr(&err)() + //defer perf.ScopeTimerErr(&err)() n, err := t.pieces[piece].Storage().WriteAt(data, begin) if err == nil && n != len(data) { err = io.ErrShortWrite