From 6e79f473f4713c97d62351510e078dd7fb0990f5 Mon Sep 17 00:00:00 2001 From: Paul Davis Date: Wed, 4 Jul 2018 15:40:47 -0400 Subject: [PATCH] ignore system reset messages entirely in the MIDI parser --- libs/midi++2/parser.cc | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/libs/midi++2/parser.cc b/libs/midi++2/parser.cc index ff0702f794..9866d41632 100644 --- a/libs/midi++2/parser.cc +++ b/libs/midi++2/parser.cc @@ -346,6 +346,13 @@ Parser::scanner (unsigned char inbyte) return; } + /* ditto for system reset, except do even less */ + + if (inbyte == 0xff) { + message_counter[inbyte]++; + return; + } + /* If necessary, allocate larger message buffer. */ if (msgindex >= msglen) { @@ -793,4 +800,3 @@ Parser::set_offline (bool yn) state = NEEDSTATUS; } } -