mirror of
https://github.com/golang/go
synced 2024-11-26 00:07:57 -07:00
net: fix race in TestReadWriteDeadline.
Discovered by adding OBLOCK support to race instrumentation. R=golang-dev, minux.ma, rsc CC=golang-dev https://golang.org/cl/6819067
This commit is contained in:
parent
27c990e794
commit
824b332652
@ -201,7 +201,7 @@ func TestReadWriteDeadline(t *testing.T) {
|
||||
|
||||
go func() {
|
||||
var buf [10]byte
|
||||
_, err = c.Read(buf[:])
|
||||
_, err := c.Read(buf[:])
|
||||
if err == nil {
|
||||
t.Errorf("Read should not succeed")
|
||||
}
|
||||
@ -212,7 +212,7 @@ func TestReadWriteDeadline(t *testing.T) {
|
||||
go func() {
|
||||
var buf [10000]byte
|
||||
for {
|
||||
_, err = c.Write(buf[:])
|
||||
_, err := c.Write(buf[:])
|
||||
if err != nil {
|
||||
break
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user