Buffer signals channel

Signed-off-by: Wangchong Zhou <fffonion@gmail.com>
This commit is contained in:
Wangchong Zhou 2019-04-22 16:35:12 -07:00
parent 383ee9bd3b
commit 47b5ef9be0
No known key found for this signature in database
GPG key ID: B607274584E8D5E5

View file

@ -260,7 +260,7 @@ func main() {
}
exporter := NewExporter(mapper)
signals := make(chan os.Signal)
signals := make(chan os.Signal, 1)
signal.Notify(signals, os.Interrupt, syscall.SIGTERM)
go exporter.Listen(events)