diff --git a/NEWS b/NEWS index 4dc6b4e06..ab03945cf 100644 --- a/NEWS +++ b/NEWS @@ -3,7 +3,7 @@ ver 0.22.1 (not yet released) - alsa: don't deadlock when the ALSA driver is buggy - jack, pulse: reduce the delay when stopping or pausing playback * playlist - - cue: fix crash bug + - cue: fix two crash bugs ver 0.22 (2020/09/23) * protocol diff --git a/src/playlist/cue/CueParser.cxx b/src/playlist/cue/CueParser.cxx index e5bd59af4..1bf260f53 100644 --- a/src/playlist/cue/CueParser.cxx +++ b/src/playlist/cue/CueParser.cxx @@ -262,7 +262,9 @@ CueParser::Feed2(char *p) noexcept if (previous != nullptr && previous->GetStartTime().ToMS() < (unsigned)position_ms) previous->SetEndTime(SongTime::FromMS(position_ms)); - current->SetStartTime(SongTime::FromMS(position_ms)); + if (current != nullptr) + current->SetStartTime(SongTime::FromMS(position_ms)); + if(strcmp(nr, "00") != 0 || previous == nullptr) ignore_index = true; }