[FFmpeg-devel] [PATCH] Fix warning in swscale.c:planarCopy()

Stefano Sabatini stefano.sabatini-lala
Sun Jan 17 01:19:02 CET 2010


On date Sunday 2010-01-17 00:10:57 +0100, Reimar D?ffinger encoded:
> On Sat, Jan 16, 2010 at 11:51:46PM +0100, Stefano Sabatini wrote:
> > Hi, fix warning:
> > swscale.c: In function ?planarCopy?:
> > swscale.c:2256: warning: cast discards qualifiers from pointer target type
> > 
> > Regards.
> > -- 
> > FFmpeg = Friendly & Fierce Minimalistic Pacific Encoding/decoding Geek
> 
> > Index: ffmpeg/libswscale/swscale.c
> > ===================================================================
> > --- ffmpeg.orig/libswscale/swscale.c	2010-01-16 23:49:49.000000000 +0100
> > +++ ffmpeg/libswscale/swscale.c	2010-01-16 23:51:03.000000000 +0100
> > @@ -2253,7 +2253,7 @@
> >  
> >                  for (i=0; i<height; i++) {
> >                      for (j=0; j<length; j++)
> > -                        ((uint16_t*)dstPtr)[j] = bswap_16(((uint16_t*)srcPtr)[j]);
> > +                        ((uint16_t*)dstPtr)[j] = bswap_16(((const uint16_t*)srcPtr)[j]);
> 
> Ok, and IMO don't send patches for just adding a const if it doesn't add any other warnings.
> We'll flame on cvslog if necessary :-)

Applied :-).
-- 
FFmpeg = Friendly & Faithless MultiPurpose Extreme Glue



More information about the ffmpeg-devel mailing list