mirror of
https://github.com/golang/sys.git
synced 2026-02-07 19:26:03 +03:00
The os/signal package drops signal notifications if the channel is not ready to receive immediately. To avoid dropping signals (for example, while processing the other branch of a 'select'), the channel must be buffered. This fixes a mistake flagged by 'go vet ./...'. Change-Id: I2a20dbe2aa27ae8ec009fff5e7be47e4409fdddd Reviewed-on: https://go-review.googlesource.com/c/sys/+/465595 Auto-Submit: Bryan Mills <bcmills@google.com> Run-TryBot: Bryan Mills <bcmills@google.com> Reviewed-by: Quim Muntal <quimmuntal@gmail.com> Reviewed-by: David Chase <drchase@google.com> TryBot-Result: Gopher Robot <gobot@golang.org>