diff options
author | Paul B Mahol <onemda@gmail.com> | 2013-09-19 17:50:18 +0000 |
---|---|---|
committer | Paul B Mahol <onemda@gmail.com> | 2013-09-19 17:50:42 +0000 |
commit | 0ad5ef674b65fe87bb948e1c200f0c320db2f869 (patch) | |
tree | e15c32ac0593fea7827f1dd3abc81cecd06c7373 | |
parent | 1f5d1342ea25abcd219c19c2adf7bfd1630daf68 (diff) | |
download | ffmpeg-0ad5ef674b65fe87bb948e1c200f0c320db2f869.tar.gz |
avfilter/vf_decimate: fix crash with gray8
Signed-off-by: Paul B Mahol <onemda@gmail.com>
-rw-r--r-- | libavfilter/vf_decimate.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libavfilter/vf_decimate.c b/libavfilter/vf_decimate.c index 8767d5f603..36284a0697 100644 --- a/libavfilter/vf_decimate.c +++ b/libavfilter/vf_decimate.c @@ -86,7 +86,7 @@ static void calc_diffs(const DecimateContext *dm, struct qitem *q, memset(bdiffs, 0, dm->bdiffsize * sizeof(*bdiffs)); - for (plane = 0; plane < (dm->chroma ? 3 : 1); plane++) { + for (plane = 0; plane < (dm->chroma && f1->data[2] ? 3 : 1); plane++) { int x, y, xl; const int linesize1 = f1->linesize[plane]; const int linesize2 = f2->linesize[plane]; |