aboutsummaryrefslogtreecommitdiffstats
path: root/libavfilter/vf_fieldorder.c
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2013-08-03 18:54:43 +0200
committerMichael Niedermayer <michaelni@gmx.at>2013-08-25 19:50:54 +0200
commit64d362fce718d5dfe108c147971ca9558f5bed24 (patch)
tree392cd1c23c25930d97202d2f988f9bd79aebfd55 /libavfilter/vf_fieldorder.c
parentc55a09a8b65f88d748daa885b4829019a081040c (diff)
downloadffmpeg-64d362fce718d5dfe108c147971ca9558f5bed24.tar.gz
avfilter: fix plane validity checks
Fixes out of array accesses Signed-off-by: Michael Niedermayer <michaelni@gmx.at> (cherry picked from commit e43a0a232dbf6d3c161823c2e07c52e76227a1bc) Conflicts: libavfilter/vf_delogo.c libavfilter/vf_fieldmatch.c libavfilter/vf_fieldorder.c libavfilter/vf_hflip.c libavfilter/vf_kerndeint.c libavfilter/vf_lut.c libavfilter/vf_pad.c libavfilter/vf_showinfo.c libavfilter/vf_vignette.c Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavfilter/vf_fieldorder.c')
-rw-r--r--libavfilter/vf_fieldorder.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libavfilter/vf_fieldorder.c b/libavfilter/vf_fieldorder.c
index 06e0369962..e2dfefe141 100644
--- a/libavfilter/vf_fieldorder.c
+++ b/libavfilter/vf_fieldorder.c
@@ -137,7 +137,7 @@ static int filter_frame(AVFilterLink *inlink, AVFilterBufferRef *frame)
"picture will move %s one line\n",
s->dst_tff ? "up" : "down");
h = frame->video->h;
- for (plane = 0; plane < 4 && frame->data[plane]; plane++) {
+ for (plane = 0; plane < 4 && frame->data[plane] && frame->linesize[plane]; plane++) {
line_step = frame->linesize[plane];
line_size = s->line_size[plane];
data = frame->data[plane];