summaryrefslogtreecommitdiff
path: root/src/lib/ffmpeg_decoder.cc
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2014-02-25 10:46:15 +0000
committerCarl Hetherington <cth@carlh.net>2014-02-25 10:46:15 +0000
commit0412f1a2b29f380cb4ca35787fc7174d6948072c (patch)
treea0f74429e57e868614da7e01a43cf9a4e73cf9e4 /src/lib/ffmpeg_decoder.cc
parenta983bc3abceadae75c7fa070ae394a69e6d8bd5b (diff)
Fix a couple of audio crashes in the film viewer. Fix serialisation of SubRipContent.
Diffstat (limited to 'src/lib/ffmpeg_decoder.cc')
-rw-r--r--src/lib/ffmpeg_decoder.cc7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/lib/ffmpeg_decoder.cc b/src/lib/ffmpeg_decoder.cc
index b7006a264..4534de589 100644
--- a/src/lib/ffmpeg_decoder.cc
+++ b/src/lib/ffmpeg_decoder.cc
@@ -136,9 +136,8 @@ FFmpegDecoder::flush ()
if (_ffmpeg_content->audio_stream() && _decode_audio) {
decode_audio_packet ();
+ AudioDecoder::flush ();
}
-
- AudioDecoder::flush ();
}
bool
@@ -391,7 +390,9 @@ void
FFmpegDecoder::seek (ContentTime time, bool accurate)
{
Decoder::seek (time, accurate);
- AudioDecoder::seek (time, accurate);
+ if (_decode_audio) {
+ AudioDecoder::seek (time, accurate);
+ }
/* If we are doing an accurate seek, our initial shot will be 200ms (200 being
a number plucked from the air) earlier than we want to end up. The loop below