aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Niedermayer <michael@niedermayer.cc>2016-10-21 14:05:00 +0200
committerMichael Niedermayer <michael@niedermayer.cc>2016-10-21 19:33:04 +0200
commit6456a7416e8f04f75752ce6174372e2fc6271a80 (patch)
treee0ab8cdd4f9680c87f429abb8aac36721bef4d0b
parentde487cb765ca5e4ecf600942809ca2d61cdbba81 (diff)
downloadffmpeg-6456a7416e8f04f75752ce6174372e2fc6271a80.tar.gz
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: Michael Niedermayer <michael@niedermayer.cc> (cherry picked from commit 03ec6b780cfae85b8bf0f32b2eda201063ad061b) Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
-rw-r--r--libavcodec/mpegvideo_enc.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/libavcodec/mpegvideo_enc.c b/libavcodec/mpegvideo_enc.c
index 87d795478a..30d2e2cfde 100644
--- a/libavcodec/mpegvideo_enc.c
+++ b/libavcodec/mpegvideo_enc.c
@@ -2911,6 +2911,8 @@ int ff_mpv_reallocate_putbitbuffer(MpegEncContext *s, size_t threshold, size_t s
return AVERROR(ENOMEM);
}
+ emms_c();
+
av_fast_padded_malloc(&new_buffer, &new_buffer_size,
s->avctx->internal->byte_buffer_size + size_increase);
if (!new_buffer)