Fix null last measure for empty MIDI files