[Top][All Lists]

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

Is AC_FUNC_MALLOC more trouble than it's worth?

From: Ronald Landheer-Cieslak
Subject: Is AC_FUNC_MALLOC more trouble than it's worth?
Date: Thu, 6 Feb 2003 12:23:57 +0100 (CET)

Hello all,

I've been using autoconf for a while now, and have been wondering about 
the use of the AC_FUNC_MALLOC and AC_FUNC_REALLOC macros: my programs use 
both malloc and realloc a lot, so it is a good idea for me to check for 
their portability, but I have never (so far) tried to allocate a block of 
0 bytes willingly (that is: we me knowing about it in advance), because I 
simply don't see the use of such a block. IMHO, that would be a waste of 
the four (or eight) bytes of memory the pointer needs.

So, I was wondering where the idea of AC_FUNC_{M|RE}ALLOC comes from: why 
it exists and what it's uses are, especially because I've been having some 
trouble getting it to behave lately (false negatives for the checks, and 
conflicts for the macros they create).

Any feedback would be more than welcome,


reply via email to

[Prev in Thread] Current Thread [Next in Thread]