Skip to content

Commit 87bcd66

Browse files
author
Justin Reagor
committed
Clean-up core signals handler by removing unnecessary cruft
1 parent 8e7f220 commit 87bcd66

1 file changed

Lines changed: 1 addition & 6 deletions

File tree

core/signals.go

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -19,17 +19,12 @@ func (a *App) handleSignals() {
1919
for {
2020
sig := <-recvSig
2121
switch sig {
22-
case syscall.SIGINT:
22+
case syscall.SIGINT, syscall.SIGTERM:
2323
a.Terminate()
24-
return
25-
case syscall.SIGTERM:
26-
a.Terminate()
27-
return
2824
case syscall.SIGHUP, syscall.SIGUSR2:
2925
if s := toString(sig); s != "" {
3026
a.SignalEvent(s)
3127
}
32-
default:
3328
}
3429
}
3530
}()

0 commit comments

Comments
 (0)