[MPlayer-dev-eng] [PATCH][BUG] Incorrect memleak fix code in input/input.c might cause incorrect free

Shachar Raindel shacharr at gmail.com
Sat Jul 31 17:34:02 CEST 2004


On Sat, 31 Jul 2004 12:24:48 +0200, Alexander Strasser <eclipse7 at gmx.net> wrote:
> Hi Shachar,
> On Mon, Jul 26, 2004 at 05:59:42PM +0200, Shachar Raindel wrote:
> > > Just a view things:
> > > >    if( mp_input_parse_config(file)) {
> > > > -    free(file); // release the buffer created by get_path()
> > > > +    //    free(file); // release the buffer created by get_path()
> > > >    }
> > > >    else {
> > > This doesn't look to nice, but maybe i'm blind again.
> > > I would suggest:
> > >     if( !mp_input_parse_config(file)) {
> > >
> > > > +  free(tmpbufptr);
> > > Maybe the freeing comment should be appended here.
> > >
> > >   Alex (beastd)
> > >
> >
> > I agree. The patch was written under time presure, and therefore I
> > hadn't had time to make it pretty. I should clean-up my tree at home
> > soon, and send some cleanup patches, so that I will not have so much
> > CVS merge problems....
> Do you want to resend a cleaned up patch?
> If not i'm going to send one and apply it asap,
> because I want to correct my mistake asap.
> 

I will try to send a better one later today, but only in the
evening/night. Feel free to submit a modified version if you have CVS
write permissions, and please notify me if you submitted, so I won't
do unneeded work.

     Cheers,
     Shachar




More information about the MPlayer-dev-eng mailing list