summaryrefslogtreecommitdiffstats
path: root/src/H5A.c
diff options
context:
space:
mode:
authorQuincey Koziol <koziol@hdfgroup.org>2007-07-24 21:43:59 (GMT)
committerQuincey Koziol <koziol@hdfgroup.org>2007-07-24 21:43:59 (GMT)
commit712c226038212283ffeefad494538d30cf767eef (patch)
treeae197744810ab7d438f00d5bc69a9f320a5ed2e0 /src/H5A.c
parentdecf1830efac293971cf7119c15fc1c9993263e9 (diff)
downloadhdf5-712c226038212283ffeefad494538d30cf767eef.zip
hdf5-712c226038212283ffeefad494538d30cf767eef.tar.gz
hdf5-712c226038212283ffeefad494538d30cf767eef.tar.bz2
[svn-r14010] Description:
Fix problem with dataspace messages where the version of the format for a dataspace message could depend on the "use the latest format" flag from the file after it was initially created. Also, move debuging routine into separate file. 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) Solaris/32 2.10 (linew)
Diffstat (limited to 'src/H5A.c')
-rw-r--r--src/H5A.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/H5A.c b/src/H5A.c
index 3ac3d52..f7d1081 100644
--- a/src/H5A.c
+++ b/src/H5A.c
@@ -358,6 +358,11 @@ H5A_create(const H5G_loc_t *loc, const char *name, const H5T_t *type,
/* Copy the dataspace for the attribute */
attr->ds = H5S_copy(space, FALSE);
+ /* Set the latest format for dataspace, if requested */
+ if(H5F_USE_LATEST_FORMAT(loc->oloc->file))
+ if(H5S_set_latest_version(attr->ds) < 0)
+ HGOTO_ERROR(H5E_DATASET, H5E_CANTSET, FAIL, "can't set latest version of dataspace")
+
/* Mark it initially set to initialized */
attr->initialized = TRUE; /*for now, set to false later*/