1
0
mirror of https://git.savannah.gnu.org/git/gnulib.git synced 2025-08-08 17:22:05 +03:00

safe-alloc: simplify via reallocarray

* lib/safe-alloc.c: Do not include xalloc-oversized.h.
(safe_alloc_alloc_n, safe_alloc_realloc_n):
Use reallocarray to check for size or ptrdiff_t overflow.
* modules/reallocarray (License): Switch from LGPL to LGPLv2+, as
this is needed for safe-alloc and anyway is more appropriate for
this library function common with BSD.
* modules/safe-alloc (Depends-on): Depend on reallocarray
rather than xalloc-oversized.
This commit is contained in:
Paul Eggert
2021-04-18 16:53:11 -07:00
parent 6c9d1972b2
commit d4e52e5e3c
4 changed files with 14 additions and 17 deletions

View File

@@ -26,7 +26,7 @@ Include:
<stdlib.h>
License:
LGPL
LGPLv2+
Maintainer:
all