diff options
author | Michael Niedermayer <michael@niedermayer.cc> | 2016-05-29 18:11:53 +0200 |
---|---|---|
committer | Michael Niedermayer <michael@niedermayer.cc> | 2016-05-29 19:00:15 +0200 |
commit | be96ebdcd795c0d5acd229251eea97f3c4bf6095 (patch) | |
tree | aa6bcb33110c55cb241ee00dd354870e675654ac /libavfilter | |
parent | 7ae4d574e87364620ac1832e538650af0bf6bf11 (diff) | |
download | ffmpeg-streaming-be96ebdcd795c0d5acd229251eea97f3c4bf6095.zip ffmpeg-streaming-be96ebdcd795c0d5acd229251eea97f3c4bf6095.tar.gz |
avfilter/vf_fieldhint: Reorder operation to prevent hypothetical integer overflow
Fixes CID1355110
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
Diffstat (limited to 'libavfilter')
-rw-r--r-- | libavfilter/vf_fieldhint.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/libavfilter/vf_fieldhint.c b/libavfilter/vf_fieldhint.c index 739c1bf..2b845e7 100644 --- a/libavfilter/vf_fieldhint.c +++ b/libavfilter/vf_fieldhint.c @@ -174,8 +174,8 @@ static int filter_frame(AVFilterLink *inlink, AVFrame *in) switch (s->mode) { case 0: - top = s->frame[1 + tf - outlink->frame_count]; - bottom = s->frame[1 + bf - outlink->frame_count]; + top = s->frame[tf - outlink->frame_count + 1]; + bottom = s->frame[bf - outlink->frame_count + 1]; break; case 1: top = s->frame[1 + tf]; |