Commit 7149fce2 authored by Chris Evans's avatar Chris Evans Committed by Michael Niedermayer

ogg: Avoid the possibility to read out-of-bounds of a static global array in Vorbis

decoding.

BUG=100543
Review URL: http://codereview.chromium.org/8365014
This fixes 25% of CVE-2011-3893
Signed-off-by: 's avatarMichael Niedermayer <michaelni@gmx.at>
parent f35e037c
...@@ -156,7 +156,7 @@ void ff_vorbis_ready_floor1_list(vorbis_floor1_entry * list, int values) ...@@ -156,7 +156,7 @@ void ff_vorbis_ready_floor1_list(vorbis_floor1_entry * list, int values)
} }
} }
static inline void render_line_unrolled(intptr_t x, intptr_t y, int x1, static inline void render_line_unrolled(intptr_t x, unsigned char y, int x1,
intptr_t sy, int ady, int adx, intptr_t sy, int ady, int adx,
float *buf) float *buf)
{ {
...@@ -191,7 +191,7 @@ static void render_line(int x0, int y0, int x1, int y1, float *buf) ...@@ -191,7 +191,7 @@ static void render_line(int x0, int y0, int x1, int y1, float *buf)
} else { } else {
int base = dy / adx; int base = dy / adx;
int x = x0; int x = x0;
int y = y0; unsigned char y = y0;
int err = -adx; int err = -adx;
ady -= FFABS(base) * adx; ady -= FFABS(base) * adx;
while (++x < x1) { while (++x < x1) {
......
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