[FFmpeg-devel] [RFC][PATCH] C89 on ffplay.c

Stefano Sabatini stefano.sabatini-lala
Sat May 15 19:35:06 CEST 2010


On date Saturday 2010-05-15 18:05:35 +0100, M?ns Rullg?rd encoded:
> "Fran?ois Revol" <revol at free.fr> writes:
> 
> > This fixes C89 for the few platforms that don't handle C99.
> >
> > Any objection ?
> >
> > Fran?ois.
> >
> > Index: ffplay.c
> > ===================================================================
> > --- ffplay.c	(revision 23142)
> > +++ ffplay.c	(working copy)
> > @@ -1567,6 +1567,7 @@
> >      int perms = AV_PERM_WRITE;
> >      int w, h, stride[4];
> >      unsigned edge;
> > +    int i;
> >  
> >      if(pic->buffer_hints & FF_BUFFER_HINTS_VALID) {
> >          if(pic->buffer_hints & FF_BUFFER_HINTS_READABLE) perms |= AV_PERM_READ;
> > @@ -1587,7 +1588,7 @@
> >  
> >      ref->w = codec->width;
> >      ref->h = codec->height;
> > -    for(int i = 0; i < 3; i ++) {
> > +    for(i = 0; i < 3; i ++) {
> >          unsigned hshift = i == 0 ? 0 : av_pix_fmt_descriptors[ref->pic->format].log2_chroma_w;
> >          unsigned vshift = i == 0 ? 0 : av_pix_fmt_descriptors[ref->pic->format].log2_chroma_h;
> >  
> 
> Obviously OK.  Mixing declarations and statements is against our rules.

Applied.
-- 
FFmpeg = Fancy & Fast Magnificient Ponderous Erotic Ghost



More information about the ffmpeg-devel mailing list