]> Cypherpunks repositories - gostls13.git/commit
net/http: fix race on postPendingDial test hook
authorTodd Neal <todd@tneal.org>
Thu, 18 Jun 2015 12:26:39 +0000 (07:26 -0500)
committerBrad Fitzpatrick <bradfitz@golang.org>
Sun, 28 Jun 2015 16:14:07 +0000 (16:14 +0000)
commit7511806ec2914f9d9b6a8941d420fb0443f5f5f6
tree5bb85555568781b6e274ad2553d903beaccaa85a
parentca91de7ca09fef7ca000fc0267918c8fdd34b429
net/http: fix race on postPendingDial test hook

The race occurs rarely, but by putting some delays and more reads/writes
of prePendingDial/postPendingDial in the handlePendingDial function I
could reproduce it.

Fixes #11136

Change-Id: I8da9e66c88fbda049eaaaaffa2717264ef327768
Reviewed-on: https://go-review.googlesource.com/11250
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
src/net/http/transport.go