aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPřemysl Eric Janouch <p@janouch.name>2022-03-16 12:32:54 +0100
committerPřemysl Eric Janouch <p@janouch.name>2022-03-16 12:33:25 +0100
commit22e386185139ffa37ce531b5ad211cecbc6ad735 (patch)
tree2b5c7fd094d8e6596422cbb64e2efa3f6c21aa3e
parent9603456cd6f76554f0be8af1eb23c20872ad8e3d (diff)
downloadhaven-22e386185139ffa37ce531b5ad211cecbc6ad735.tar.gz
haven-22e386185139ffa37ce531b5ad211cecbc6ad735.tar.xz
haven-22e386185139ffa37ce531b5ad211cecbc6ad735.zip
hswg: use a buffered channel for signals
Found by go vet.
-rw-r--r--hswg/main.go2
1 files changed, 1 insertions, 1 deletions
diff --git a/hswg/main.go b/hswg/main.go
index 65557c5..313d2ff 100644
--- a/hswg/main.go
+++ b/hswg/main.go
@@ -494,7 +494,7 @@ func main() {
log.Fatalln(err)
}
- signals := make(chan os.Signal)
+ signals := make(chan os.Signal, 1)
signal.Notify(signals, syscall.SIGINT, syscall.SIGHUP, syscall.SIGTERM)
for {
select {