summaryrefslogtreecommitdiff
path: root/tests/xmalloc.c
diff options
context:
space:
mode:
authorJörg Frings-Fürst <debian@jff.email>2024-10-20 15:21:58 +0200
committerJörg Frings-Fürst <debian@jff.email>2024-10-20 15:21:58 +0200
commit630f99f29bd31a76d8d24da2975a045452c763ef (patch)
tree0c801f68561bfb0930a4ade80d7ca3a7940887ab /tests/xmalloc.c
parent84e26c587987e8484d55db4165f188b40c09e94b (diff)
parent4682deeb62247d34de87f8e777f99e2d337fd377 (diff)
Update upstream source from tag 'upstream/1.3'
Update to upstream version '1.3' with Debian dir 8a8e4828ddf646ece6c109b401e08d162be35936
Diffstat (limited to 'tests/xmalloc.c')
-rw-r--r--tests/xmalloc.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/tests/xmalloc.c b/tests/xmalloc.c
index 82e54ef1..5befdab7 100644
--- a/tests/xmalloc.c
+++ b/tests/xmalloc.c
@@ -30,7 +30,7 @@
#include <string.h>
static void * _GL_ATTRIBUTE_PURE
-nonnull (void *p)
+check_nonnull (void *p)
{
if (!p)
xalloc_die ();
@@ -42,13 +42,13 @@ nonnull (void *p)
void *
xmalloc (size_t s)
{
- return nonnull (malloc (s));
+ return check_nonnull (malloc (s));
}
void *
ximalloc (idx_t s)
{
- return nonnull (imalloc (s));
+ return check_nonnull (imalloc (s));
}
char *
@@ -72,7 +72,7 @@ xrealloc (void *p, size_t s)
void *
xirealloc (void *p, idx_t s)
{
- return nonnull (irealloc (p, s));
+ return check_nonnull (irealloc (p, s));
}
/* Change the size of an allocated block of memory P to an array of N
@@ -90,7 +90,7 @@ xreallocarray (void *p, size_t n, size_t s)
void *
xireallocarray (void *p, idx_t n, idx_t s)
{
- return nonnull (ireallocarray (p, n, s));
+ return check_nonnull (ireallocarray (p, n, s));
}
/* Allocate an array of N objects, each with S bytes of memory,
@@ -295,13 +295,13 @@ xizalloc (idx_t s)
void *
xcalloc (size_t n, size_t s)
{
- return nonnull (calloc (n, s));
+ return check_nonnull (calloc (n, s));
}
void *
xicalloc (idx_t n, idx_t s)
{
- return nonnull (icalloc (n, s));
+ return check_nonnull (icalloc (n, s));
}
/* Clone an object P of size S, with error checking. There's no need