1
0
mirror of https://github.com/golang/go synced 2024-11-23 22:20:02 -07:00

net: remove dead code in Write

Also, please be informed that the Write method on both connected and
unconnected-mode sockets may return a positive number of bytes written
with timeout or use of closed network connection error.

Change-Id: I2e2e6192e29cef4e9389eb0422c605c6d12e6a3c
Reviewed-on: https://go-review.googlesource.com/9466
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
This commit is contained in:
Mikio Hara 2015-04-29 13:15:22 +09:00
parent 4b23b50fb4
commit a0cff2989a

View File

@ -311,7 +311,6 @@ func (fd *netFD) Write(p []byte) (nn int, err error) {
} }
} }
if err != nil { if err != nil {
n = 0
break break
} }
if n == 0 { if n == 0 {