From 2122a428cdab2abd46e9f742e54a25f6ea6b6b9f Mon Sep 17 00:00:00 2001 From: Dana Robinson <43805+derobins@users.noreply.github.com> Date: Fri, 20 Nov 2020 10:11:36 -0800 Subject: Corrects use of unitialized bytes in the chunk_info test (#106) --- test/chunk_info.c | 4 ++-- 1 file 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 */ -- cgit v0.12