This is the mail archive of the gdb-patches@sources.redhat.com mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: [RFA] Change free to xfree


Kevin Buettner wrote:
> > retrieving revision 1.5
> > diff -p -u -w -r1.5 remote-utils.h
> > --- remote-utils.h    2000/11/03 22:00:56     1.5
> > +++ remote-utils.h    2001/01/24 17:35:50
> > @@ -53,7 +53,7 @@ extern struct _sr_settings sr_settings;
> >  #define sr_get_device()                      (sr_settings.device)
> >  #define sr_set_device(newval) \
> >  { \
> > -    if (sr_settings.device) free(sr_settings.device); \
> > +    if (sr_settings.device) xfree(sr_settings.device); \
> >      sr_settings.device = (newval); \
> >  }
> 
> This one needs to be fixed so that it adheres to the GNU coding
> conventions.  (You need a space between the function name ``xfree''
> and the left paren.  FWIW, I found this hard to get used to and
> still occassionally make a mistake on these myself.)

FYI, I wouldn't worry about fixing things like this (or PTR) in this
pass (Although, I'm not going to stop you if you do :-)
Here the objective is to just flush free() - problems can be fixed in
other separate passes.

A jumbo patch that does one thing is always going to get the thumbs up
quicker than a patch that does one thing ``but wait there's more''.  (Of
course that is never always possible :-)

	enjoy,
		Andrew

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]