From ec5d4f7f0525a39dab9d26d360c2c931cdc3d0f6 Mon Sep 17 00:00:00 2001 From: Carl Hetherington Date: Fri, 12 Sep 2014 00:11:23 +0100 Subject: Add context menu option to re-examine content (#339). --- src/lib/audio_decoder.cc | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'src/lib/audio_decoder.cc') diff --git a/src/lib/audio_decoder.cc b/src/lib/audio_decoder.cc index bd9dff8c9..756192286 100644 --- a/src/lib/audio_decoder.cc +++ b/src/lib/audio_decoder.cc @@ -173,6 +173,13 @@ AudioDecoder::audio (shared_ptr data, ContentTime time) void AudioDecoder::add (shared_ptr data) { + if (!_audio_position) { + /* This should only happen when there is a seek followed by a flush, but + we need to cope with it. + */ + return; + } + /* Resize _decoded_audio to fit the new data */ int new_size = 0; if (_decoded_audio.audio->frames() == 0) { -- cgit v1.2.3