[MPlayer-dev-eng] Re: Endpos for Mplayer.

D Richard Felker III dalias at aerifal.cx
Tue Oct 21 15:40:08 CEST 2003


On Tue, Oct 21, 2003 at 12:30:53PM +0300, Konstantinos Karydas wrote:
> > > +// --> kkar part added from mencoder
> > Who added/removed what is avaible from cvs log. No needed to start
> > cluttering the code with useless comments like that.
> >
> 
> I am commenting to make the changed code more easy to read and understand
> for the others. I think this is a recommended programming practice, isn't

Knowing who added the code does not aid in reading it. Comments are
for explaining tricky bits of code that might not otherwise be clear,
not for cluttering the screen and making the code harder to read. If
anyone has trouble with your code and needs to see who added it, they
can look back to the cvslog. But I promise you, if everyone added
comments like that with every patch, mplayer would be 99% comments and
totally unreadable!

> > > +  /*if (stop_to_sec) {
> > > +    int a,b; float d;
> > > +
> > > +    if (sscanf(stop_to_sec, "%d:%d:%f", &a,&b,&d)==3)
> > > +	rel_stop_secs += 3600*a +60*b +d ;
> > > +    else if (sscanf(stop_to_sec, "%d:%f", &a, &d)==2)
> > > +	rel_stop_secs += 60*a +d;
> > > +    else if (sscanf(stop_to_sec, "%f", &d)==1)
> > > +	rel_stop_secs += d;
> > > +
> > > +     stop_to_sec = NULL;
> > > +  }	*/
> > > +
> > What is that for ? And where is rel_stop_secs declared ?
> > 	Albeu
> > --
> 
> As you can see these lines are commented out, i.e. not used. I had an idea
> some time before that didn't work so I commented this out.

Then it doesn't need to be in the patch.

Rich



More information about the MPlayer-dev-eng mailing list