Fix panic on shutdown

This commit is contained in:
Julian Kornberger 2016-03-07 10:28:24 +01:00
parent 1fd59e6156
commit 93fafcb8e2
1 changed files with 6 additions and 2 deletions

View File

@ -90,6 +90,10 @@ func main() {
log.Println("received", sig) log.Println("received", sig)
// Close everything at the end // Close everything at the end
wsserverForNodes.Close() if wsserverForNodes != nil {
respondDaemon.Close() wsserverForNodes.Close()
}
if respondDaemon != nil {
respondDaemon.Close()
}
} }