summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorQuincey Koziol <koziol@hdfgroup.org>2000-11-11 22:22:12 (GMT)
committerQuincey Koziol <koziol@hdfgroup.org>2000-11-11 22:22:12 (GMT)
commitdaeb159cb858cb4da82d5d8874388105c163ec3a (patch)
tree1a098b1155dc4f23205564714be0e7c1fbeb3d2b /src
parent51608fceef939f8f867da697d6bf3e96672ccbec (diff)
downloadhdf5-daeb159cb858cb4da82d5d8874388105c163ec3a.zip
hdf5-daeb159cb858cb4da82d5d8874388105c163ec3a.tar.gz
hdf5-daeb159cb858cb4da82d5d8874388105c163ec3a.tar.bz2
[svn-r2869] Purpose:
Bug fix Description: "old-style" compound datatypes with array fields were leaking memory during the datatype header decoding when creating the array datatype for a field. Solution: Free the base type of the array after creating array datatype for field. Platforms tested: Solaris 2.6 (baldric)
Diffstat (limited to 'src')
-rw-r--r--src/H5Odtype.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/H5Odtype.c b/src/H5Odtype.c
index a0cfa49..6d77194 100644
--- a/src/H5Odtype.c
+++ b/src/H5Odtype.c
@@ -267,6 +267,9 @@ H5O_dtype_decode_helper(H5F_t *f, const uint8_t **pp, H5T_t *dt)
H5MM_xfree(dt->u.compnd.memb);
HRETURN_ERROR(H5E_DATATYPE, H5E_CANTREGISTER, FAIL, "unable to create array datatype");
}
+
+ /* Close the base type for the array */
+ H5T_close(temp_type);
/* Make the array type the type that is set for the field */
temp_type=array_dt;