summaryrefslogtreecommitdiffstats
path: root/src/H5Gnode.c
diff options
context:
space:
mode:
authorQuincey Koziol <koziol@hdfgroup.org>2005-10-03 05:50:05 (GMT)
committerQuincey Koziol <koziol@hdfgroup.org>2005-10-03 05:50:05 (GMT)
commite21f821fc3cf10a549ccb849174b8a5a8f7cc90a (patch)
tree200ec069508aa5b2f831cfda31c0b239a0f5d1cc /src/H5Gnode.c
parentc13178a42d007a4fb209d9b07bc2b018ac2756e4 (diff)
downloadhdf5-e21f821fc3cf10a549ccb849174b8a5a8f7cc90a.zip
hdf5-e21f821fc3cf10a549ccb849174b8a5a8f7cc90a.tar.gz
hdf5-e21f821fc3cf10a549ccb849174b8a5a8f7cc90a.tar.bz2
[svn-r11490] Purpose:
Bug fix Description: Fix "double root open" bug and apply same fix to datasets & named datatypes. Also fix bug in symbol table entry lookup code that would "transfer" an object from one file handle to another file handle when the two file handles were opened on the same actual file. Platforms tested: FreeBSD 4.11 (sleipnir) Too minor to require h5committest
Diffstat (limited to 'src/H5Gnode.c')
-rw-r--r--src/H5Gnode.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/H5Gnode.c b/src/H5Gnode.c
index f21d0fd..faff6ba 100644
--- a/src/H5Gnode.c
+++ b/src/H5Gnode.c
@@ -996,6 +996,13 @@ H5G_node_found(H5F_t *f, hid_t dxpl_id, haddr_t addr, const void UNUSED *_lt_key
if (H5G_ent_copy(udata->ent, &sn->entry[idx], H5G_COPY_NULL)<0)
HGOTO_ERROR(H5E_SYM, H5E_CANTINIT, FAIL, "unable to copy entry");
+ /* Leave object in same file as lookup occurs in */
+ /* If a file is opened through different H5Fopen() calls, the symbol
+ * table entry from the B-tree lookup ("&sn->entry[idx]" above) will be
+ * in the "first" file, but the lookup might occur in the second file. - QAK
+ */
+ udata->ent->file = f;
+
done:
if (sn && H5AC_unprotect(f, dxpl_id, H5AC_SNODE, addr, sn, H5AC__NO_FLAGS_SET) < 0)
HDONE_ERROR(H5E_SYM, H5E_PROTECT, FAIL, "unable to release symbol table node");