1
0
mirror of https://github.com/golang/go synced 2024-11-19 05:44:40 -07:00
go/src
Ian Lance Taylor 8d6fc84986 internal/poll: don't take read lock in SetBlocking
Taking a read lock in SetBlocking could cause SetBlocking to block
waiting for a Read in another goroutine to complete. Since SetBlocking
is called by os.(*File).Fd, that could lead to deadlock if the
goroutine calling Fd is going to use it to unblock the Read.
Use an atomic store instead.

Updates #24481

Change-Id: I79413328e06ddf28b6d5b8af7a0e29d5b4e1e6ff
Reviewed-on: https://go-review.googlesource.com/123176
Run-TryBot: Ian Lance Taylor <iant@golang.org>
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
2018-07-11 00:34:18 +00:00
..
archive
bufio
builtin
bytes bytes, strings: fix comparison of long byte slices on s390x 2018-06-29 20:48:07 +00:00
cmd internal/poll: don't take read lock in SetBlocking 2018-07-11 00:34:18 +00:00
compress
container
context
crypto crypto/x509: better debug output for verify-cert calls 2018-06-28 02:46:18 +00:00
database/sql
debug debug/elf,macho,pe: support compressed DWARF 2018-06-19 22:13:51 +00:00
encoding
errors
expvar
flag flag: add a Value example 2018-06-21 23:32:53 +00:00
fmt
go go/types: ignore artificial cycles introduced via method declarations 2018-07-10 16:36:50 +00:00
hash
html html/template: ignore untyped nil arguments to default escapers 2018-07-09 21:54:35 +00:00
image all: clean up some Deprecated comments 2018-07-06 17:40:56 +00:00
index/suffixarray
internal internal/poll: don't take read lock in SetBlocking 2018-07-11 00:34:18 +00:00
io
log
math
mime mime/quotedprintable: accept bytes >= 0x80 2018-06-27 17:00:08 +00:00
net net/http: clarify when it's allowed to reuse a Request 2018-07-10 21:41:58 +00:00
os internal/poll: don't take read lock in SetBlocking 2018-07-11 00:34:18 +00:00
path
plugin
reflect reflect: remove struct tags from unexported types 2018-06-28 23:06:00 +00:00
regexp regexp: revert "use sync.Pool to cache regexp.machine objects" 2018-07-09 15:12:53 +00:00
runtime runtime/cgo: Add initial NetBSD Thread Sanitizer support 2018-07-10 23:14:31 +00:00
sort
strconv
strings strings: do much less redundant testing in TestCompareStrings 2018-07-02 14:39:29 +00:00
sync sync: fix deficiency in RWMutex race annotations 2018-06-22 14:43:09 +00:00
syscall syscall/js: improve panic messages 2018-07-09 23:04:30 +00:00
testing testing/cover: improve comments on CoverBlock 2018-07-01 08:07:47 +00:00
text html/template: ignore untyped nil arguments to default escapers 2018-07-09 21:54:35 +00:00
time time: clarify Unix, UnixNano, and In a bit 2018-06-29 23:01:49 +00:00
unicode unicode: fix SpecialCase to follow its docs & respect explict no-op mappings 2018-06-17 08:48:39 +00:00
unsafe
vendor/golang_org/x vendor: update vendored x/net/http/httpproxy 2018-07-09 19:35:21 +00:00
all.bash
all.bat
all.rc
androidtest.bash
bootstrap.bash
buildall.bash
clean.bash
clean.bat
clean.rc
cmp.bash
iostest.bash
make.bash make.bash: don't pass GOOS and GOARCH to cmd/go when finding GOROOT_BOOTSTRAP 2018-06-20 16:04:33 +00:00
make.bat
Make.dist
make.rc
naclmake.bash
nacltest.bash
race.bash runtime/cgo: Add initial NetBSD Thread Sanitizer support 2018-07-10 23:14:31 +00:00
race.bat
run.bash
run.bat
run.rc