1
0
mirror of https://github.com/golang/go synced 2024-11-23 05:00:07 -07:00
go/misc/cgo/testsanitizers
Cherry Mui 62e1302267 misc/cgo/testsanitizers: use buffered channel in tsan12.go
os/signal.Notify requires that "the caller must ensure that c has
sufficient buffer space to keep up with the expected signal rate"
as it does a nonblocking send when it receives a signal. The test
currently using a unbuffered channel, which means it may miss the
signal if the signal arrives before the channel receive operation.

Fixes #52998.

Change-Id: Icdcab9396d735506480ef880fb45a4669fa7cc8f
Reviewed-on: https://go-review.googlesource.com/c/go/+/407888
Reviewed-by: Ian Lance Taylor <iant@google.com>
Reviewed-by: Bryan Mills <bcmills@google.com>
Run-TryBot: Cherry Mui <cherryyz@google.com>
Reviewed-by: Cuong Manh Le <cuong.manhle.vn@gmail.com>
TryBot-Result: Gopher Robot <gobot@golang.org>
2022-05-24 14:30:46 +00:00
..
testdata misc/cgo/testsanitizers: use buffered channel in tsan12.go 2022-05-24 14:30:46 +00:00
asan_test.go cmd/dist: add asan tests for global objects in testsanitizers package 2022-05-05 04:05:43 +00:00
cc_test.go misc/cgo/testsanitizers: terminate commands with SIGQUIT if hung 2022-05-23 21:33:54 +00:00
cshared_test.go all: update references to symbols moved from io/ioutil to io 2021-04-05 17:51:15 +00:00
msan_test.go runtime/cgo: when using msan explicitly unpoison cgoCallers 2021-08-09 14:48:39 +00:00
tsan_test.go