View Single Post
Old 03-28-2018, 03:55 PM   #1
juliansader
Human being with feelings
 
Join Date: Jul 2009
Posts: 3,714
Default ReaScript: Editing text or sysex event position immediately crashes REAPER (FIXED)

If a script changes the position of a text or sysex event, resulting in a (temporary) negative offset between the text/sysex events, REAPER immediately crashes.

This can happen with the functions MIDI_SetAllEvts, MIDI_SetEvt and MIDI_SetTextSysexEvt (with nosort=true).

For example, starting with three text events such as:



Running the following simple script (which moves event 3 to the start of the take) immediately crashes REAPER:

Code:
take = reaper.MIDIEditor_GetTake(reaper.MIDIEditor_GetActive())
reaper.MIDI_SetTextSysexEvt(take, 2, true, false, 0, nil, "", true)
(REAPER x64 v5.70, v5.79pre, etc)
juliansader is offline   Reply With Quote