likely fix for crash in MidiBuffer::merge_in_place() due to unwarranted assumption in the code
git-svn-id: svn://localhost/ardour2/branches/3.0@11051 d708f5d6-7413-0410-9779-e7cbd77b26cf
This commit is contained in:
parent
8d05ed8e8a
commit
302ac289ba
@ -506,6 +506,16 @@ MidiBuffer::merge_in_place(const MidiBuffer &other)
|
||||
|
||||
} else if (them != other.end()) {
|
||||
|
||||
if ((*us).time() < ((*them).time())) {
|
||||
|
||||
/* just append the rest of other */
|
||||
|
||||
memcpy (_data + us.offset, other._data + them.offset, other._size - them.offset);
|
||||
_size += other._size - them.offset;
|
||||
assert(_size <= _capacity);
|
||||
break;
|
||||
}
|
||||
|
||||
/* to get here implies that we've encountered two
|
||||
* messages with the same timestamp. we must order
|
||||
* them correctly.
|
||||
|
Loading…
Reference in New Issue
Block a user