Backported bug fix from 'empty-cue-in-subtitles' branch.