Bruno Haible wrote:
> The bug Richard Lloyd reported was caused by the use of the "old"
> idioms for function replacement, which don't allow a "#undef" for
> reverting to the system's original definition. But such a "#undef"
> is needed when lib/setenv.c is compiled as part of the relocwrapper
> programs.
>
> As indicated in
> <http://lists.gnu.org/archive/html/bug-gnulib/2010-06/msg00145.html>
> most of the AC_FUNC_* macros that require replacement code will soon
> defer to gnulib. Here we have the same situation for AC_FUNC_MALLOC and
> AC_FUNC_REALLOC.

Thanks for diagnosing and fixing that.

> Here are 3 patches to drop the uses of AC_FUNC_MALLOC and AC_FUNC_REALLOC.
> In this proposal instead we would use _AC_FUNC_MALLOC_IF and
> _AC_FUNC_REALLOC_IF, which are defined in Autoconf but undocumented.
> I'm not sure which is better: using these undocumented macros, or
> copying their code from Autoconf? (For calloc, gnulib already has its
> own copy of _AC_FUNC_CALLOC_IF.)
>
> OK to apply?

Looks good to me and passed this smoke test:
  ./gnulib-tool --create-testdir --with-tests --test malloc realloc calloc
so yes.

Richard, thanks again for the non-gcc testing and report.
We don't get much of that, these days.

Reply via email to