diff options
author | Max Kellermann <max@duempel.org> | 2011-03-16 19:13:46 +0100 |
---|---|---|
committer | Max Kellermann <max@duempel.org> | 2011-03-16 19:16:06 +0100 |
commit | b6303313f0145c4caf58195ba4a85d2f4fa2967c (patch) | |
tree | 352ba4ea4bd48c95b71692a53923c7acc4968c1b /src/encoder/vorbis_encoder.c | |
parent | 6dcec366214da4238819914985e4921e258ba324 (diff) | |
download | mpd-b6303313f0145c4caf58195ba4a85d2f4fa2967c.tar.gz mpd-b6303313f0145c4caf58195ba4a85d2f4fa2967c.tar.xz mpd-b6303313f0145c4caf58195ba4a85d2f4fa2967c.zip |
encoder/vorbis: reset the Ogg stream after flush
Without the ogg_stream_reset() call, the "e_o_s" flag never gets
reset, and libogg writes EOS packets over and over.
Diffstat (limited to 'src/encoder/vorbis_encoder.c')
-rw-r--r-- | src/encoder/vorbis_encoder.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/encoder/vorbis_encoder.c b/src/encoder/vorbis_encoder.c index 9dac3564d..08147be1c 100644 --- a/src/encoder/vorbis_encoder.c +++ b/src/encoder/vorbis_encoder.c @@ -276,6 +276,8 @@ vorbis_encoder_flush(struct encoder *_encoder, G_GNUC_UNUSED GError **error) vorbis_analysis_init(&encoder->vd, &encoder->vi); vorbis_block_init(&encoder->vd, &encoder->vb); + ogg_stream_reset(&encoder->os); + encoder->flush = true; return true; } |