diff options
author | Quincey Koziol <koziol@hdfgroup.org> | 2007-07-24 19:10:00 (GMT) |
---|---|---|
committer | Quincey Koziol <koziol@hdfgroup.org> | 2007-07-24 19:10:00 (GMT) |
commit | 492e5ca2b48782bb4759ee1d0a59b0210f011528 (patch) | |
tree | f2c334cd5e2afb9ca40492340efe57d1f3af1ae6 /src/H5A.c | |
parent | 05973a4e8610a7f6893d0eaed9c3eee3b008ba60 (diff) | |
download | hdf5-492e5ca2b48782bb4759ee1d0a59b0210f011528.zip hdf5-492e5ca2b48782bb4759ee1d0a59b0210f011528.tar.gz hdf5-492e5ca2b48782bb4759ee1d0a59b0210f011528.tar.bz2 |
[svn-r14004] Description:
Fix problem with datatype messages where the version of the format
for a datatype message could depend on the "use the latest format" flag from
the file after it was initially created.
Tested on:
FreeBSD/32 6.2 (duty)
FreeBSD/64 6.2 (liberty)
Linux/32 2.6 (kagiso)
Mac OS X/32 10.4.10 (amazon)
Diffstat (limited to 'src/H5A.c')
-rw-r--r-- | src/H5A.c | 5 |
1 files changed, 5 insertions, 0 deletions
@@ -350,6 +350,11 @@ H5A_create(const H5G_loc_t *loc, const char *name, const H5T_t *type, if(H5T_set_loc(attr->dt, loc->oloc->file, H5T_LOC_DISK) < 0) HGOTO_ERROR(H5E_DATATYPE, H5E_CANTINIT, FAIL, "invalid datatype location") + /* Set the latest format for datatype, if requested */ + if(H5F_USE_LATEST_FORMAT(loc->oloc->file)) + if(H5T_set_latest_version(attr->dt) < 0) + HGOTO_ERROR(H5E_DATASET, H5E_CANTSET, FAIL, "can't set latest version of datatype") + /* Copy the dataspace for the attribute */ attr->ds = H5S_copy(space, FALSE); |