mirror of
https://github.com/Ardour/ardour.git
synced 2026-01-04 12:45:45 +01:00
Fix various MIDI corruption bugs.
Re-enable MIDI CC controller bars and other immediate output (hans commented out, tsk tsk). Write channel mode as textual enumeration instead of magic number. Better atomic (almost) channel mode switching on MIDI ring buffer (was a possible, if unlikely, source of corruption). Handle some cases of broken MIDI, and oversized events, more gracefully. git-svn-id: svn://localhost/ardour2/branches/3.0@3335 d708f5d6-7413-0410-9779-e7cbd77b26cf
This commit is contained in:
parent
a76e2128ef
commit
8ca72c4eca
17 changed files with 351 additions and 297 deletions
|
|
@ -195,7 +195,10 @@ MidiBuffer::push_back(const jack_midi_event_t& ev)
|
|||
Byte*
|
||||
MidiBuffer::reserve(double time, size_t size)
|
||||
{
|
||||
assert(size <= MAX_EVENT_SIZE);
|
||||
if (size > MAX_EVENT_SIZE) {
|
||||
cerr << "WARNING: Failed to reserve " << size << " bytes for event";
|
||||
return 0;
|
||||
}
|
||||
|
||||
if (_size == _capacity)
|
||||
return 0;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue