fix: benchmark read bytes

This commit is contained in:
Dreamacro 2022-05-23 12:58:18 +08:00 committed by 世界
parent 186a4cfdf3
commit 15ecc451f3
No known key found for this signature in database
GPG key ID: CD109927C34A63C4

View file

@ -658,7 +658,7 @@ func benchmarkProxy(b *testing.B, proxy C.ProxyAdapter) {
b.SetBytes(chunkSize)
buf := make([]byte, chunkSize)
for i := 0; i < b.N; i++ {
conn.Read(buf)
io.ReadFull(conn, buf)
}
})
}