Fix meta_len MIDI entry parsing
meta_length is a varlen, not a single byte. Use get_varlen() to handle >127 byte entries automatically.
This commit is contained in:
1 parent
e11da8c325
commit
4b52ce7397
1 file changed
+1
-1
@@ -213,7 +213,7 @@ void AudioGeneratorMIDI::find_note (int tracknum) {
|
||||
}
|
||||
if (event == 0xff) { /* meta-event */
|
||||
meta_cmd = buffer_byte (t->trkptr++);
|
||||
meta_length = buffer_byte (t->trkptr++);
|
||||
meta_length = get_varlen(&t->trkptr);
|
||||
switch (meta_cmd) {
|
||||
case 0x00:
|
||||
break;
|
||||
|
||||
Reference in new issue
Block a user