Make events chan local to supervisor

Signed-off-by: Michael Crosby <crosbymichael@gmail.com>
This commit is contained in:
Michael Crosby
2015-12-02 17:44:39 -08:00
parent 5eac8891ed
commit 3ea5dd79e0
2 changed files with 4 additions and 8 deletions

View File

@@ -89,10 +89,9 @@ func daemon(stateDir string, concurrency, bufferSize int) error {
w := containerd.NewWorker(supervisor, wg)
go w.Start()
}
events := make(chan *containerd.Event, bufferSize)
// start the signal handler in the background.
go startSignalHandler(supervisor, bufferSize)
if err := supervisor.Start(events); err != nil {
if err := supervisor.Start(); err != nil {
return err
}
server := v1.NewServer(supervisor)