mirror of
https://github.com/golang/go.git
synced 2025-11-11 14:11:04 +00:00
net: dialChannel should not treat an expired deadline as noDeadline.
Now, only a zero deadline is interpreted as noDeadline. Any other time in the past yields an immediate timeout. TestConnectDeadlineInThePast already covers this case. We just need to un-skip it for plan9, where dialChannel is used. Change-Id: I995fd1a632c31f8004dac772c3d7c43a2a5853b0 Reviewed-on: https://go-review.googlesource.com/8435 Reviewed-by: Mikio Hara <mikioh.mikioh@gmail.com>
This commit is contained in:
parent
5242d2cef4
commit
c50a8416c8
2 changed files with 5 additions and 10 deletions
|
|
@ -682,11 +682,6 @@ func TestAcceptDeadlineConnectionAvailable(t *testing.T) {
|
|||
// TestConnectDeadlineInThePast tests that connect deadlines work, even
|
||||
// if the connection can be established w/o blocking.
|
||||
func TestConnectDeadlineInThePast(t *testing.T) {
|
||||
switch runtime.GOOS {
|
||||
case "plan9":
|
||||
t.Skipf("skipping test on %q", runtime.GOOS)
|
||||
}
|
||||
|
||||
ln := newLocalListener(t).(*TCPListener)
|
||||
defer ln.Close()
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue