diff options
author | jstebbins <[email protected]> | 2015-05-01 14:47:35 +0000 |
---|---|---|
committer | jstebbins <[email protected]> | 2015-05-01 14:47:35 +0000 |
commit | 58b25a7664d9d063b404ec39270ff4cdfa333979 (patch) | |
tree | 3807be923b500ddc3f618170b7bd7c4900204bdd /libhb/stream.c | |
parent | 3e30a6ef3a449ac4cadb60fa738cc58f974c1794 (diff) |
libhb: Use a buffer flat to indicate EOF
... instead of a 0 length buffer.
This fixes this issue:
https://forum.handbrake.fr/viewtopic.php?f=12&t=31959
Theora can create 0 length output. These 0 length frames indicate
duplicate frames. So we can't use 0 length buffers to indicate the end
of the stream.
git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@7143 b64f7644-9d1e-0410-96f1-a4d463321fa5
Diffstat (limited to 'libhb/stream.c')
-rw-r--r-- | libhb/stream.c | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/libhb/stream.c b/libhb/stream.c index 5713f6dee..166830a5d 100644 --- a/libhb/stream.c +++ b/libhb/stream.c @@ -5712,12 +5712,9 @@ hb_buffer_t * hb_ffmpeg_read( hb_stream_t *stream ) // following them to preserve the timing (since the packing puts two // or more frames in what looks like one avi frame). The contents and // size of these null frames are ignored by the ff_h263_decode_frame - // as long as they're < 20 bytes. We need a positive size so we use - // one byte if we're given a zero or negative size. We don't know - // if the pkt data points anywhere reasonable so we just stick a - // byte of zero in our outbound buf. - buf = hb_buffer_init( 1 ); - *buf->data = 0; + // as long as they're < 20 bytes. Zero length buffers are also + // use by theora to indicate duplicate frames. + buf = hb_buffer_init( 0 ); } else { |