linthesia
linthesia copied to clipboard
[LIBMIDI]remove hack with lastEvent = -1 (though it's an unsigned number...)
in libmidi , the MidiTrack::reset method set lastEvent to -1 though it's an unsigned (so as you guess we got an integer overflow)
it does not cause any bug , because we always use it with +1 , but well that's a hack...
I've started to mark the place where to lastEvent with a comment containing "#3" to make it easier to track