Commit 5a446bc8 authored by Loren Merritt's avatar Loren Merritt

fix an overflow in vc1 intra overlap filter

Originally committed as revision 16845 to svn://svn.ffmpeg.org/ffmpeg/trunk
parent b69201a8
......@@ -45,8 +45,8 @@ static void vc1_v_overlap_c(uint8_t* src, int stride)
d2 = (a - d + b - c + 4 - rnd) >> 3;
src[-2*stride] = a - d1;
src[-stride] = b - d2;
src[0] = c + d2;
src[-stride] = av_clip_uint8(b - d2);
src[0] = av_clip_uint8(c + d2);
src[stride] = d + d1;
src++;
rnd = !rnd;
......@@ -70,8 +70,8 @@ static void vc1_h_overlap_c(uint8_t* src, int stride)
d2 = (a - d + b - c + 4 - rnd) >> 3;
src[-2] = a - d1;
src[-1] = b - d2;
src[0] = c + d2;
src[-1] = av_clip_uint8(b - d2);
src[0] = av_clip_uint8(c + d2);
src[1] = d + d1;
src += stride;
rnd = !rnd;
......
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