diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2013-08-03 18:54:43 +0200 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2013-08-03 19:15:46 +0200 |
commit | e43a0a232dbf6d3c161823c2e07c52e76227a1bc (patch) | |
tree | 6ccf4fedf12be91e9de6f73fee41d202612916b5 /libavfilter/vf_kerndeint.c | |
parent | bc4e7985628134496104e32f37f811aab4f68c55 (diff) | |
download | ffmpeg-e43a0a232dbf6d3c161823c2e07c52e76227a1bc.tar.gz |
avfilter: fix plane validity checks
Fixes out of array accesses
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavfilter/vf_kerndeint.c')
-rw-r--r-- | libavfilter/vf_kerndeint.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libavfilter/vf_kerndeint.c b/libavfilter/vf_kerndeint.c index 5f99d88c2b..5f81525527 100644 --- a/libavfilter/vf_kerndeint.c +++ b/libavfilter/vf_kerndeint.c @@ -150,7 +150,7 @@ static int filter_frame(AVFilterLink *inlink, AVFrame *inpic) av_frame_copy_props(outpic, inpic); outpic->interlaced_frame = 0; - for (plane = 0; inpic->data[plane] && plane < 4; plane++) { + for (plane = 0; plane < 4 && inpic->data[plane] && inpic->linesize[plane]; plane++) { h = plane == 0 ? inlink->h : FF_CEIL_RSHIFT(inlink->h, kerndeint->vsub); bwidth = kerndeint->tmp_bwidth[plane]; |