Commit 6456a741 authored by Michael Niedermayer's avatar Michael Niedermayer

avcodec/mpegvideo_enc: Clear mmx state in ff_mpv_reallocate_putbitbuffer()

This function must be called from the mb or slice encoding loop and MMX state may not
be clean there
Signed-off-by: 's avatarMichael Niedermayer <michael@niedermayer.cc>
(cherry picked from commit 03ec6b78)
Signed-off-by: 's avatarMichael Niedermayer <michael@niedermayer.cc>
parent de487cb7
...@@ -2911,6 +2911,8 @@ int ff_mpv_reallocate_putbitbuffer(MpegEncContext *s, size_t threshold, size_t s ...@@ -2911,6 +2911,8 @@ int ff_mpv_reallocate_putbitbuffer(MpegEncContext *s, size_t threshold, size_t s
return AVERROR(ENOMEM); return AVERROR(ENOMEM);
} }
emms_c();
av_fast_padded_malloc(&new_buffer, &new_buffer_size, av_fast_padded_malloc(&new_buffer, &new_buffer_size,
s->avctx->internal->byte_buffer_size + size_increase); s->avctx->internal->byte_buffer_size + size_increase);
if (!new_buffer) if (!new_buffer)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment