This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] Fix gensupport.c memory leak (take 3)


Hi Andrew,

On Thu, 16 Mar 2006, Andrew Pinski wrote:
> You really don't need the if here as free handles NULL pointers just
> fine.

The "if" isn't required for correct operation on C99 targets,
but by the GCC coding standards.  Its a historic portability issue.
I believe you were reminded of this when you suggested a similar
change to Uttam's original gensupport.c patch, and why his version
with ifs was approved over the version without.

http://gcc.gnu.org/ml/gcc-patches/2006-02/msg01889.html

I hope this helps.

Roger
--


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