|
|
@ -1045,11 +1045,14 @@ do {\ |
|
|
|
|
|
|
|
|
|
|
|
if (s1->bitstream_buffer) { |
|
|
|
if (s1->bitstream_buffer) { |
|
|
|
if (s1->bitstream_buffer_size + |
|
|
|
if (s1->bitstream_buffer_size + |
|
|
|
FF_INPUT_BUFFER_PADDING_SIZE > s->allocated_bitstream_buffer_size) |
|
|
|
FF_INPUT_BUFFER_PADDING_SIZE > s->allocated_bitstream_buffer_size) { |
|
|
|
av_fast_malloc(&s->bitstream_buffer, |
|
|
|
av_fast_malloc(&s->bitstream_buffer, |
|
|
|
&s->allocated_bitstream_buffer_size, |
|
|
|
&s->allocated_bitstream_buffer_size, |
|
|
|
s1->allocated_bitstream_buffer_size); |
|
|
|
s1->allocated_bitstream_buffer_size); |
|
|
|
s->bitstream_buffer_size = s1->bitstream_buffer_size; |
|
|
|
if (!s->bitstream_buffer) |
|
|
|
|
|
|
|
return AVERROR(ENOMEM); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
s->bitstream_buffer_size = s1->bitstream_buffer_size; |
|
|
|
memcpy(s->bitstream_buffer, s1->bitstream_buffer, |
|
|
|
memcpy(s->bitstream_buffer, s1->bitstream_buffer, |
|
|
|
s1->bitstream_buffer_size); |
|
|
|
s1->bitstream_buffer_size); |
|
|
|
memset(s->bitstream_buffer + s->bitstream_buffer_size, 0, |
|
|
|
memset(s->bitstream_buffer + s->bitstream_buffer_size, 0, |
|
|
|