Issue on MidiClip::extendStart (double newStartTime)

Hi,
When i try to use the method MidiClip::extendStart (double newStartTime) ( passing a newStartTime
value that is less then the currentStartTime ) it crashs when calling the getSequence().moveAllBeatPositions (offsetNeededInBeats, getUndoManager()) method.

To be more specific, exactly after added the second midiNote to the sequence and called the extendStart method the method getSequence().moveAllBeatPositions (offsetNeededInBeats, getUndoManager()) perform a loop on each notes,controller events and SysexEvents founding the notes in a dirty state ( their pointer has may be deleted ) causing a crash.

StackTrace :

Exeption:

What is the delta in this situation?

Do you have a small piece of test code I could run? Just looking at the code, I’m struggling to see where the notes would get deleted whilst being iterated as nothing should be removing them from the MidiList state tree?