diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2012-12-19 14:55:07 +0100 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2012-12-19 15:44:59 +0100 |
commit | 642a655f7d9a6afc97fff5f3ecd6a7ad5d53e0ca (patch) | |
tree | b09ea65812ccdada345d88802afa71016e1b357e /libavcodec/mpegvideo_enc.c | |
parent | e84194f06024892fc33684c5a1726c97a0c0a45c (diff) | |
parent | f1d8763a02b5fce9a7d9789e049d74a45b15e1e8 (diff) | |
download | ffmpeg-streaming-642a655f7d9a6afc97fff5f3ecd6a7ad5d53e0ca.zip ffmpeg-streaming-642a655f7d9a6afc97fff5f3ecd6a7ad5d53e0ca.tar.gz |
Merge commit 'f1d8763a02b5fce9a7d9789e049d74a45b15e1e8'
* commit 'f1d8763a02b5fce9a7d9789e049d74a45b15e1e8':
mpegvideo: allocate scratch buffers after linesize is known
Conflicts:
libavcodec/mpegvideo.c
Merged-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavcodec/mpegvideo_enc.c')
-rw-r--r-- | libavcodec/mpegvideo_enc.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/libavcodec/mpegvideo_enc.c b/libavcodec/mpegvideo_enc.c index aff12c6..45e8c77 100644 --- a/libavcodec/mpegvideo_enc.c +++ b/libavcodec/mpegvideo_enc.c @@ -3228,7 +3228,7 @@ static void set_frame_distances(MpegEncContext * s){ static int encode_picture(MpegEncContext *s, int picture_number) { - int i; + int i, ret; int bits; int context_count = s->slice_context_count; @@ -3278,7 +3278,9 @@ static int encode_picture(MpegEncContext *s, int picture_number) s->mb_intra=0; //for the rate distortion & bit compare functions for(i=1; i<context_count; i++){ - ff_update_duplicate_context(s->thread_context[i], s); + ret = ff_update_duplicate_context(s->thread_context[i], s); + if (ret < 0) + return ret; } if(ff_init_me(s)<0) |