[pacman-dev] [PATCH] Add remove counterparts to alpm_option_add_* functions

Nagy Gabor ngaba at bibl.u-szeged.hu
Sun Dec 23 19:23:59 EST 2007


> Nagy Gabor wrote:
> >> Updated patch attached without the memory leaks and adding return
> >> of removal success.
> >>
> >> Cheers,
> >> Allan
> >>     
> >
> > Is newcachedir freed?;-)
> > Bye
> >
> >   
> No... but it wasn't in alpm_option_add_cachedir() either and I was 
> trying for coding style consistency. :)  Both are fixed in attached
> patch.
No. You mustn't free it in add_cachedir, because alpm_list_add just adds
a POINTER to the (handle->cachedirs) list. (So you can always think
alpm_list as a list of pointers.)

Bye




More information about the pacman-dev mailing list