aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2013-09-15 16:33:27 +0200
committerMichael Niedermayer <michaelni@gmx.at>2013-09-23 21:46:15 +0200
commit0a64b25c77320577a54203b2c7e5f3da4ae36e40 (patch)
tree3038680cbbc289ea9377010013429d9128290aa9
parent40e52bbb63cfa7a143ba9c335a09701fe9235200 (diff)
downloadffmpeg-0a64b25c77320577a54203b2c7e5f3da4ae36e40.tar.gz
avcodec/g2meet: Fix order of align and pixel size multiplication.
Fixes out of array accesses Fixes Ticket2922 Found-by: ami_stuff Signed-off-by: Michael Niedermayer <michaelni@gmx.at> (cherry picked from commit 821a5938d100458f4d09d634041b05c860554ce0) Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
-rw-r--r--libavcodec/g2meet.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libavcodec/g2meet.c b/libavcodec/g2meet.c
index d31fc54ca8..1822c5e274 100644
--- a/libavcodec/g2meet.c
+++ b/libavcodec/g2meet.c
@@ -453,7 +453,7 @@ static int g2m_init_buffers(G2MContext *c)
if (!c->synth_tile || !c->jpeg_tile ||
c->old_tile_w < c->tile_width ||
c->old_tile_h < c->tile_height) {
- c->tile_stride = FFALIGN(c->tile_width * 3, 16);
+ c->tile_stride = FFALIGN(c->tile_width, 16) * 3;
aligned_height = FFALIGN(c->tile_height, 16);
av_free(c->synth_tile);
av_free(c->jpeg_tile);