summaryrefslogtreecommitdiffstats
path: root/test/testframe.c
diff options
context:
space:
mode:
authorDana Robinson <43805+derobins@users.noreply.github.com>2023-06-28 22:48:12 (GMT)
committerGitHub <noreply@github.com>2023-06-28 22:48:12 (GMT)
commitaebac33a1f290fa5065bce96bb0512317a34c283 (patch)
treecdbae6dbd65a2eb4e6f786921ee907cec92c92d3 /test/testframe.c
parent605cea4af60cfcbe03a54f697de392eec75e5a85 (diff)
downloadhdf5-aebac33a1f290fa5065bce96bb0512317a34c283.zip
hdf5-aebac33a1f290fa5065bce96bb0512317a34c283.tar.gz
hdf5-aebac33a1f290fa5065bce96bb0512317a34c283.tar.bz2
Remove HD from memory allocate/free calls (#3195)
* HDcalloc * HDfree * HDmalloc * HDrealloc
Diffstat (limited to 'test/testframe.c')
-rw-r--r--test/testframe.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/test/testframe.c b/test/testframe.c
index ea5cc18..cd2947b 100644
--- a/test/testframe.c
+++ b/test/testframe.c
@@ -74,11 +74,11 @@ AddTest(const char *TheName, void (*TheCall)(void), void (*Cleanup)(void), const
if (HDstrlen(TheDescr) >= MAXTESTDESC) {
printf("Test description ('%s') too long, increase MAXTESTDESC(%d).\n", TheDescr, MAXTESTDESC);
HDexit(EXIT_FAILURE);
- } /* end if */
+ }
if (HDstrlen(TheName) >= MAXTESTNAME) {
printf("Test name too long, increase MAXTESTNAME(%d).\n", MAXTESTNAME);
HDexit(EXIT_FAILURE);
- } /* end if */
+ }
/* Check for increasing the Test array size */
if (Index >= TestAlloc) {
@@ -86,16 +86,16 @@ AddTest(const char *TheName, void (*TheCall)(void), void (*Cleanup)(void), const
unsigned newAlloc = MAX(1, TestAlloc * 2); /* New array size */
/* Reallocate array */
- if (NULL == (newTest = (TestStruct *)HDrealloc(Test, newAlloc * sizeof(TestStruct)))) {
+ if (NULL == (newTest = (TestStruct *)realloc(Test, newAlloc * sizeof(TestStruct)))) {
printf("Out of memory for tests, Index = %u, TestAlloc = %u, newAlloc = %u\n", Index, TestAlloc,
newAlloc);
HDexit(EXIT_FAILURE);
- } /* end if */
+ }
/* Update info */
Test = newTest;
TestAlloc = newAlloc;
- } /* end if */
+ }
/* Set up test function */
HDstrcpy(Test[Index].Description, TheDescr);
@@ -378,7 +378,7 @@ void
TestShutdown(void)
{
if (Test)
- HDfree(Test);
+ free(Test);
}
/*