diff options
author | Raymond Lu <songyulu@hdfgroup.org> | 2004-06-17 16:53:26 (GMT) |
---|---|---|
committer | Raymond Lu <songyulu@hdfgroup.org> | 2004-06-17 16:53:26 (GMT) |
commit | ec6ff32ec720c6073dca3139e4146e66aba7b60d (patch) | |
tree | 8fcea1fe0e0539076e862d71e31b9e2fe260d303 /src/H5Tconv.c | |
parent | 65370b8417550b503ce1df7727edcac6f2657aba (diff) | |
download | hdf5-ec6ff32ec720c6073dca3139e4146e66aba7b60d.zip hdf5-ec6ff32ec720c6073dca3139e4146e66aba7b60d.tar.gz hdf5-ec6ff32ec720c6073dca3139e4146e66aba7b60d.tar.bz2 |
[svn-r8699] Purpose: Bug fix and new test.
Description: A user reported a bug on Windows when writing data of array data
type of compound type with variable-length type. I didn't see any problem on
Unix. But Purify revealed some memory errors and leaks.
Solution: Fixed memory leaks and added new test for it.
Platforms tested: h5committest.
Diffstat (limited to 'src/H5Tconv.c')
-rw-r--r-- | src/H5Tconv.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/H5Tconv.c b/src/H5Tconv.c index 95ba6c2..ece4341 100644 --- a/src/H5Tconv.c +++ b/src/H5Tconv.c @@ -2628,7 +2628,7 @@ H5T_conv_array(hid_t src_id, hid_t dst_id, H5T_cdata_t *cdata, size_t nelmts, if(tpath->cdata.need_bkg) { /* Allocate background buffer */ bkg_buf_size=src->u.array.nelem*MAX(src->size,dst->size); - if ((bkg_buf=H5FL_BLK_MALLOC(array_seq,bkg_buf_size))==NULL) + if ((bkg_buf=H5FL_BLK_CALLOC(array_seq,bkg_buf_size))==NULL) HGOTO_ERROR (H5E_RESOURCE, H5E_NOSPACE, FAIL, "memory allocation failed for type conversion"); } /* end if */ |