[MPlayer-dev-eng] [PATCH]Fix FFmpeg warning

Diego Biurrun diego at biurrun.de
Sat Mar 10 18:30:34 CET 2012


On Sat, Mar 10, 2012 at 06:55:30AM +0000, Carl Eugen Hoyos wrote:
> Diego Biurrun <diego <at> biurrun.de> writes:
> > > > > -static struct vf_priv_s {
> > > > > +struct vf_priv_s {
> > > > >          unsigned char *buf;
> > > > >          int brightness;
> > > > >          int contrast;
> > > > > -} const vf_priv_dflt = {
> > > > > +} static const vf_priv_dflt = {
> > > 
> > > > This looks wrong.
> > > 
> > > Please elaborate.
> > 
> > gcc can complain about static not being the first keyword in declarations
> > in -Wextra mode. 
> 
> True, but we do not use -Wextra
> Do you plan to add it?

We do, in debug mode.

> > So I wonder what the warning you are trying to fix here
> > is in the first place.  Just splitting the struct and the variable
> > declaration could be simpler in any case.
> 
> Please elaborate what is "wrong" about above patch.

static should be the first keyword, your patch moves it to an awkward
place.  Now could we please see the warning finally?  Also please test
with -Wextra, exchanging one warning for another is hardly an
improvement.

Diego


More information about the MPlayer-dev-eng mailing list