summaryrefslogtreecommitdiffstats
path: root/test/chunk_info.c
diff options
context:
space:
mode:
authorDana Robinson <43805+derobins@users.noreply.github.com>2020-11-20 18:11:36 (GMT)
committerGitHub <noreply@github.com>2020-11-20 18:11:36 (GMT)
commit2122a428cdab2abd46e9f742e54a25f6ea6b6b9f (patch)
treee6cde440568a87df1f91dc79ad231c9073cc40ca /test/chunk_info.c
parent8c330c1cb410250e373b335fb4fba944822a2ef0 (diff)
downloadhdf5-2122a428cdab2abd46e9f742e54a25f6ea6b6b9f.zip
hdf5-2122a428cdab2abd46e9f742e54a25f6ea6b6b9f.tar.gz
hdf5-2122a428cdab2abd46e9f742e54a25f6ea6b6b9f.tar.bz2
Corrects use of unitialized bytes in the chunk_info test (#106)
Diffstat (limited to 'test/chunk_info.c')
-rw-r--r--test/chunk_info.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/test/chunk_info.c b/test/chunk_info.c
index f45a4dd..d22d44b 100644
--- a/test/chunk_info.c
+++ b/test/chunk_info.c
@@ -542,7 +542,7 @@ test_get_chunk_info_highest_v18(hid_t fapl)
#ifdef H5_HAVE_FILTER_DEFLATE
/* Allocate input (compressed) buffer */
- inbuf = HDmalloc(z_dst_nbytes);
+ inbuf = HDcalloc(1, z_dst_nbytes);
/* Set chunk size to the compressed chunk size and the chunk point
to the compressed data chunk */
@@ -567,7 +567,7 @@ test_get_chunk_info_highest_v18(hid_t fapl)
}
#else
/* Allocate input (non-compressed) buffer */
- inbuf = HDmalloc(CHK_SIZE);
+ inbuf = HDcalloc(1, CHK_SIZE);
HDmemcpy(inbuf, direct_buf, CHK_SIZE);
#endif /* end H5_HAVE_FILTER_DEFLATE */