mirror of
https://github.com/golang/go
synced 2024-09-05 16:04:50 +00:00
internal: use time.Since instead of time.Now().Sub
Change-Id: I536c7fad84a63e96658c6930a5a77fd70edca33c Reviewed-on: https://go-review.googlesource.com/c/go/+/436718 Reviewed-by: Ian Lance Taylor <iant@google.com> TryBot-Result: Gopher Robot <gobot@golang.org> Reviewed-by: Dmitri Shuralyov <dmitshur@google.com> Auto-Submit: Ian Lance Taylor <iant@google.com> Run-TryBot: Ian Lance Taylor <iant@google.com>
This commit is contained in:
parent
b8ed88db8d
commit
daf1612dc7
|
@ -792,7 +792,7 @@ func (ws *workerServer) fuzz(ctx context.Context, args fuzzArgs) (resp fuzzRespo
|
|||
|
||||
func (ws *workerServer) minimize(ctx context.Context, args minimizeArgs) (resp minimizeResponse) {
|
||||
start := time.Now()
|
||||
defer func() { resp.Duration = time.Now().Sub(start) }()
|
||||
defer func() { resp.Duration = time.Since(start) }()
|
||||
mem := <-ws.memMu
|
||||
defer func() { ws.memMu <- mem }()
|
||||
vals, err := unmarshalCorpusFile(mem.valueCopy())
|
||||
|
|
Loading…
Reference in a new issue