summaryrefslogtreecommitdiffstats
path: root/tools/test/h5jam
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 /tools/test/h5jam
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 'tools/test/h5jam')
-rw-r--r--tools/test/h5jam/getub.c10
-rw-r--r--tools/test/h5jam/h5jamgentest.c6
2 files changed, 8 insertions, 8 deletions
diff --git a/tools/test/h5jam/getub.c b/tools/test/h5jam/getub.c
index 192371d..5ac9c7f 100644
--- a/tools/test/h5jam/getub.c
+++ b/tools/test/h5jam/getub.c
@@ -120,7 +120,7 @@ main(int argc, char *argv[])
goto error;
} /* end if */
- if (NULL == (buf = (char *)HDmalloc((unsigned)(size + 1)))) {
+ if (NULL == (buf = (char *)malloc((unsigned)(size + 1)))) {
error_msg("can't allocate buffer \n");
goto error;
} /* end if */
@@ -137,15 +137,15 @@ main(int argc, char *argv[])
} /* end if */
/* close things and exit */
- HDfree(filename);
- HDfree(buf);
+ free(filename);
+ free(buf);
HDclose(fd);
return EXIT_SUCCESS;
error:
- HDfree(filename);
- HDfree(buf);
+ free(filename);
+ free(buf);
if (fd >= 0)
HDclose(fd);
return EXIT_FAILURE;
diff --git a/tools/test/h5jam/h5jamgentest.c b/tools/test/h5jam/h5jamgentest.c
index a9df43b..96e6407 100644
--- a/tools/test/h5jam/h5jamgentest.c
+++ b/tools/test/h5jam/h5jamgentest.c
@@ -369,7 +369,7 @@ create_textfile(const char *name, size_t size)
if ((fd = HDcreat(name, 0777)) < 0)
goto error;
- if (NULL == (buf = (char *)HDcalloc(size, 1)))
+ if (NULL == (buf = (char *)calloc(size, 1)))
goto error;
/* Fill buf with pattern */
@@ -380,13 +380,13 @@ create_textfile(const char *name, size_t size)
if (HDwrite(fd, buf, size) < 0)
goto error;
- HDfree(buf);
+ free(buf);
HDclose(fd);
return SUCCEED;
error:
- HDfree(buf);
+ free(buf);
if (fd >= 0)
HDclose(fd);