fix illegal MIDI event message during import

This happens when reimporting a MIDI file taken from Ardour, which
has sequencer specific data (namely, note-IDs). In that case
SMF::read_event() returns zero to indicate a meta event that we
should or could be interested in. For import, we are not interested,
hence the ignored_note_id variable
This commit is contained in:
Paul Davis 2025-11-17 14:39:06 -07:00
parent 65332e603b
commit 6dfca90b8e

View file

@ -405,6 +405,11 @@ write_midi_type0_data_to_one_file (Evoral::SMF* source, ImportStatus& status, si
continue; continue;
} }
if (ret == 0) {
/* set note id, but we ignored it */
continue;
}
if (size > bufsize) { if (size > bufsize) {
bufsize = size; bufsize = size;
} }