Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/FFmpeg/FFmpeg.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDyami Caliri <dyami@dragonframe.com>2015-02-26 21:17:01 +0300
committerMichael Niedermayer <michaelni@gmx.at>2015-02-26 22:14:00 +0300
commit50833c9f7b4e1922197a8955669f8ab3589c8cef (patch)
tree6be84f8ce9233207b72499d91e6e55594f010631 /libavcodec/flashsvenc.c
parentb851bc20c6931c084710e69f7eec30d8c1bdb68e (diff)
Fix buffer_size argument to init_put_bits() in multiple encoders.
Several encoders were multiplying the buffer size by 8, in order to get a bit size. However, the buffer_size argument is for the byte size of the buffer. We had experienced crashes encoding prores (Anatoliy) at size 4096x4096.
Diffstat (limited to 'libavcodec/flashsvenc.c')
-rw-r--r--libavcodec/flashsvenc.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libavcodec/flashsvenc.c b/libavcodec/flashsvenc.c
index a6d7caa97b..14e8adab2e 100644
--- a/libavcodec/flashsvenc.c
+++ b/libavcodec/flashsvenc.c
@@ -151,7 +151,7 @@ static int encode_bitstream(FlashSVContext *s, const AVFrame *p, uint8_t *buf,
int buf_pos, res;
int pred_blocks = 0;
- init_put_bits(&pb, buf, buf_size * 8);
+ init_put_bits(&pb, buf, buf_size);
put_bits(&pb, 4, block_width / 16 - 1);
put_bits(&pb, 12, s->image_width);