[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)
This commit is contained in:
Quincey Koziol 2000-11-11 17:22:12 -05:00
parent 51608fceef
commit daeb159cb8

View File

@ -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;