summaryrefslogtreecommitdiff
path: root/pkg/controller
diff options
context:
space:
mode:
authorChristian Pointner <equinox@spreadspace.org>2020-03-03 19:19:01 +0100
committerChristian Pointner <equinox@spreadspace.org>2020-03-03 19:19:01 +0100
commit61f587cfc6f151570df169ae38158b6293aaddb8 (patch)
tree790dfd7292452564f52aad4f23ff0be6a31e46ee /pkg/controller
parenthack: listen on all addresses for websocket clients (diff)
add go-modules support and fix midi library API changetopic/x32-midi
Diffstat (limited to 'pkg/controller')
-rw-r--r--pkg/controller/controller.go10
1 files changed, 6 insertions, 4 deletions
diff --git a/pkg/controller/controller.go b/pkg/controller/controller.go
index 2aa8023..dfb6d7d 100644
--- a/pkg/controller/controller.go
+++ b/pkg/controller/controller.go
@@ -162,11 +162,13 @@ func (c *Controller) Init() error {
go func() {
for {
- p := <-ch
- if p.Err != nil {
- c.Shutdown()
+ ps := <-ch
+ for _, p := range ps {
+ if p.Err != nil {
+ c.Shutdown()
+ }
+ c.handleMidiPacket(p)
}
- c.handleMidiPacket(p)
}
}()
return nil