MIDI event decoder: prevent running status after sysex

Running status cannot be using in the command immediately following
a system exclusive command, so we have to reset the running status
state in that case.

Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
This commit is contained in:
Clemens Ladisch 2009-06-22 10:00:03 +02:00
parent e94f3cfdf9
commit cbf395d692

View file

@ -442,6 +442,7 @@ long snd_midi_event_decode(snd_midi_event_t *dev, unsigned char *buf, long count
if (cmd == MIDI_CMD_COMMON_SYSEX) {
snd_midi_event_reset_decode(dev);
qlen = ev->data.ext.len;
if (count < qlen)
return -ENOMEM;