[FFmpeg-devel] [PATCH] Make ffserver use parse_options()

Stefano Sabatini stefano.sabatini-lala
Mon May 19 09:29:41 CEST 2008


On date Monday 2008-05-19 03:03:46 +0200, Michael Niedermayer encoded:
> On Sun, May 18, 2008 at 08:34:36PM +0200, Stefano Sabatini wrote:
> > On date Sunday 2008-05-18 14:29:48 +0200, Michael Niedermayer encoded:
> > > On Sun, May 18, 2008 at 09:38:55AM +0200, Stefano Sabatini wrote:
> > [...]
> > > > > > I prefer to define consistently all the opt_* before the options
> > > > > > array, anyway i reckon this is just pickyness so do as you prefer.
> > > > > 
> > > > > Well then define them all before the array, its not my fault if you do not.
> > > > 
> > > > No I can't because opt_show_help() uses the options array itself, so I
> > > > have to define it before.
> > > 
> > > You can forward declare the array ...
> [...]
> > @@ -4339,10 +4329,40 @@
> >      need_to_start_children = 1;
> >  }
> >  
> > +static void opt_show_license(void)
> > +{
> > +    show_license();
> > +    exit(0);
> > +}
> > +
> > +static void opt_debug()
> > +{
> > +    ffserver_debug = 1;
> > +    ffserver_daemon = 0;
> > +}
> > +
> > +static const OptionDef options[];
> > +
> > +static void opt_show_help(void)
> 
> Please place the declarartion before all functions and stuctures
> It does not belong in the middle of the file, just think of the case
> that the array becomed needed a line above ...
[...]

OK, regards.
-- 
FFmpeg = Fast and Fiendish MultiPurpose EnGine
-------------- next part --------------
A non-text attachment was scrubbed...
Name: make-ffserver-use-parse-options-03.patch
Type: text/x-diff
Size: 2897 bytes
Desc: not available
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/attachments/20080519/0907658e/attachment.patch>



More information about the ffmpeg-devel mailing list