]> Cypherpunks repositories - gostls13.git/commit
net: prevent spurious TCP connection setup notification on darwin
authorMikio Hara <mikioh.mikioh@gmail.com>
Wed, 9 Mar 2016 09:16:00 +0000 (18:16 +0900)
committerMikio Hara <mikioh.mikioh@gmail.com>
Wed, 16 Mar 2016 03:09:28 +0000 (03:09 +0000)
commit76b724cc6367309b046a9fc09d81b73f0dcccca4
tree4b7b94d30792f84969c30096fa7db78bdea88aac
parent5ce0170a26fc60bfde176cb9c09d2a47fac94cd3
net: prevent spurious TCP connection setup notification on darwin

On the latest darwin kernels, kevent in runtime-integrated network
poller sometimes reports SYN-SENT state sockets as ESTABLISHED ones,
though it's still unclear what's the root cause.

This change prevents such spurious notifications by additional connect
system calls.

Fixes #14548.

Change-Id: Ie29788e38ca735ca77259befeba3229d6a30ac52
Reviewed-on: https://go-review.googlesource.com/20468
Run-TryBot: Mikio Hara <mikioh.mikioh@gmail.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Ian Lance Taylor <iant@golang.org>
src/net/error_unix_test.go
src/net/fd_unix.go
src/net/tcpsock_unix_test.go [new file with mode: 0644]