[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
gnulib module 'realloc-gnu' will go away
From: |
Bruno Haible |
Subject: |
gnulib module 'realloc-gnu' will go away |
Date: |
Sun, 27 Oct 2024 22:33:28 +0100 |
Hi,
inetutils uses gnulib module 'realloc-gnu' (see bootstrap.conf line 88).
I suggest to use gnulib module 'realloc-posix' instead.
Rationale:
* Gnulib module 'realloc-gnu' will be removed in a few days, because
it conflicts with another module that we are going to add.
* I checked all realloc() calls in inetutils, and except for one,
they all pass a size > 0 (barring integer overflow, of course),
thus the requirement regarding size == 0 [1] are irrelevant.
* The one call that can pass a zero size argument is in
libtelnet/forward.c:347.
The code there interprets a successful return (with a NULL pointer)
as an error. So this code will only be _less_ broken, not more broken,
if a different realloc behaviour is encountered.
* The new realloc behaviour that we plan for Gnulib will be such that
the _current_ code in libtelnet/forward.c:347 will be correct.
But it's not ready yet. Until then, please use module 'realloc-posix'.
Bruno
[1] https://www.gnu.org/software/libc/manual/html_node/Changing-Block-Size.html
- gnulib module 'realloc-gnu' will go away,
Bruno Haible <=