summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/H5HF.c6
-rw-r--r--src/H5HFhdr.c3
2 files changed, 3 insertions, 6 deletions
diff --git a/src/H5HF.c b/src/H5HF.c
index cc38f2a..23e15c2 100644
--- a/src/H5HF.c
+++ b/src/H5HF.c
@@ -859,9 +859,6 @@ HDfprintf(stderr, "%s; After iterator reset fh->hdr->rc = %Zu\n", FUNC, fh->hdr-
if(NULL == (hdr = H5HF_hdr_protect(fh->f, dxpl_id, heap_addr, H5AC_WRITE)))
HGOTO_ERROR(H5E_HEAP, H5E_CANTPROTECT, FAIL, "unable to protect fractal heap header")
- /* Set the shared heap header's file context for this operation */
- hdr->f = fh->f;
-
/* Delete heap, starting with header (unprotects header) */
if(H5HF_hdr_delete(hdr, dxpl_id) < 0)
HGOTO_ERROR(H5E_HEAP, H5E_CANTDELETE, FAIL, "unable to delete fractal heap")
@@ -913,9 +910,6 @@ HDfprintf(stderr, "%s: fh_addr = %a\n", FUNC, fh_addr);
if(hdr->file_rc)
hdr->pending_delete = TRUE;
else {
- /* Set the shared heap header's file context for this operation */
- hdr->f = f;
-
/* Delete heap now, starting with header (unprotects header) */
if(H5HF_hdr_delete(hdr, dxpl_id) < 0)
HGOTO_ERROR(H5E_HEAP, H5E_CANTDELETE, FAIL, "unable to delete fractal heap")
diff --git a/src/H5HFhdr.c b/src/H5HFhdr.c
index e678d74..684c171 100644
--- a/src/H5HFhdr.c
+++ b/src/H5HFhdr.c
@@ -552,6 +552,9 @@ H5HF_hdr_protect(H5F_t *f, hid_t dxpl_id, haddr_t addr, H5AC_protect_t rw)
/* Set the header's address */
hdr->heap_addr = addr;
+ /* Update header's file pointer */
+ hdr->f = f;
+
/* Set the return value */
ret_value = hdr;