Re: [PATCH] Remove useless if-before-free tests.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



> +inline void gitfree(void *ptr)
>  +{
>  +       if (ptr)
>  +               free(ptr);
>  +}
>  +#define free gitfree
>  +#endif

I am wondering why you do it this way.  "#define free gitfree" is just
not valid in a C program that includes the relevant standard header.
"free" is a reserved symbol.

To stay within the standard, do the define the other way and use
gitfree everywhere.

Morten
-
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux