[MPlayer-cvslog] CVS: main m_config.c, 1.11, 1.12 m_config.h, 1.6, 1.7 parser-cfg.c, 1.7, 1.8

Alban Bedel albeu at free.fr
Wed Jan 25 11:47:04 CET 2006


On Tue, 24 Jan 2006 21:31:52 +0100
Diego Biurrun <diego at biurrun.de> wrote:

> On Tue, Jan 24, 2006 at 12:16:16PM +0100, Alban Bedel CVS wrote:
> > 
> > Modified Files:
> > 	m_config.c m_config.h parser-cfg.c 
> > Log Message:
> > Profiles support.
> > 
> > +  static m_option_t ref_opts[] = {
> > +    { "profile", NULL, &profile_opt_type, CONF_NOSAVE, 0, 0, NULL },
> > +    { "show-profile", show_profile, CONF_TYPE_PRINT_FUNC, CONF_NOCFG, 0, 0, NULL },
> > +    { NULL, NULL, NULL, 0, 0, 0, NULL }
> > +  };
> 
> Are these options in the man page?  I think not..

They are, read the (man page) diff more carefully.
 
> > +static int
> > +parse_profile(m_option_t* opt,char *name, char *param, void* dst, int src) {
> > +  m_config_t* config = opt->priv;
> > +  char** list = NULL;
> > +  int i,r;
> > +  if(param && !strcmp(param,"help")) {
> > +    m_profile_t* p;
> > +    if(!config->profiles) {
> > +      mp_msg(MSGT_FIXME, MSGL_FIXME, "No profile have been defined.\n");
> > +      return M_OPT_EXIT-1;
> > +    }
> > +    mp_msg(MSGT_FIXME, MSGL_FIXME, "Available profiles:\n");
> > +    for(p = config->profiles ; p ; p = p->next)
> > +      mp_msg(MSGT_FIXME, MSGL_FIXME, "\t%s\t%s\n",p->name,
> > +	     p->desc ? p->desc : "");
> > +    mp_msg(MSGT_FIXME, MSGL_FIXME, "\n");
> 
> Please replace the MSGT_FIXME and MSGL_FIXME with something sane.  All
> of them while you're at it ;)

I'll look at that, as well as the fixes suggested by The Wanderer.

> > +		if(profile) {
> > +			if(!strcmp(opt,"profile-desc"))
> > +				m_profile_set_desc(profile,param), tmp = 1;
> 
> Neither is this option, IIRC.

This one isn't bcs it is not an option. It's part of the profile definition
and as such only valid their. It's already mentioned in the profiles section
and shown in the example. So to me it didn't make much sense to put that
with the other options.

	Albeu




More information about the MPlayer-cvslog mailing list