[FFmpeg-devel] [PATCH 1/2] avcodec/dca_xll: Fix runtime error: signed integer overflow: 2147286116 + 6298923 cannot be represented in type 'int'

Michael Niedermayer michael at niedermayer.cc
Sun Mar 12 04:09:12 EET 2017


On Fri, Mar 10, 2017 at 03:52:06PM +0100, wm4 wrote:
> On Fri, 10 Mar 2017 15:24:51 +0100
> Michael Niedermayer <michael at niedermayer.cc> wrote:
> 
> > Fixes: 732/clusterfuzz-testcase-4872990070145024
> > 
> > See: [FFmpeg-devel] [PATCH 2/6] avcodec/dca_xll: Fix runtime error: signed integer overflow: 2147286116 + 6298923 cannot be represented in type 'int'
> > Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/targets/ffmpeg
> > Signed-off-by: Michael Niedermayer <michael at niedermayer.cc>
> > ---
> >  libavcodec/dca_xll.c | 2 +-
> >  1 file changed, 1 insertion(+), 1 deletion(-)
> > 
> > diff --git a/libavcodec/dca_xll.c b/libavcodec/dca_xll.c
> > index 6cebda35e4..0fe90c7348 100644
> > --- a/libavcodec/dca_xll.c
> > +++ b/libavcodec/dca_xll.c
> > @@ -1312,7 +1312,7 @@ static int combine_residual_frame(DCAXllDecoder *s, DCAXllChSet *c)
> >          } else {
> >              // No downmix scaling
> >              for (n = 0; n < nsamples; n++)
> > -                dst[n] += (src[n] + round) >> shift;
> > +                dst[n] += (unsigned)((src[n] + round) >> shift);
> >          }
> >      }
> >  
> 
> Seems reasonable.

applied

thx

-- 
Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

I do not agree with what you have to say, but I'll defend to the death your
right to say it. -- Voltaire
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 181 bytes
Desc: Digital signature
URL: <http://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20170312/c4713c66/attachment.sig>


More information about the ffmpeg-devel mailing list