diff options
Diffstat (limited to 'src/H5Gint.c')
-rw-r--r-- | src/H5Gint.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/H5Gint.c b/src/H5Gint.c index c78c87c..f5bccc3 100644 --- a/src/H5Gint.c +++ b/src/H5Gint.c @@ -472,6 +472,7 @@ done: herr_t H5G_close(H5G_t *grp) { + hbool_t corked; /* Whether the group is corked or not */ herr_t ret_value = SUCCEED; /* Return value */ FUNC_ENTER_NOAPI(FAIL) @@ -485,6 +486,13 @@ H5G_close(H5G_t *grp) if(0 == grp->shared->fo_count) { HDassert(grp != H5G_rootof(H5G_fileof(grp))); + /* Uncork cache entries with object address tag */ + if(H5AC_cork(grp->oloc.file, grp->oloc.addr, H5AC__GET_CORKED, &corked) < 0) + HGOTO_ERROR(H5E_SYM, H5E_CANTGET, FAIL, "unable to retrieve an object's cork status") + if(corked) + if(H5AC_cork(grp->oloc.file, grp->oloc.addr, H5AC__UNCORK, NULL) < 0) + HGOTO_ERROR(H5E_SYM, H5E_CANTUNCORK, FAIL, "unable to uncork an object") + /* Remove the group from the list of opened objects in the file */ if(H5FO_top_decr(grp->oloc.file, grp->oloc.addr) < 0) HGOTO_ERROR(H5E_SYM, H5E_CANTRELEASE, FAIL, "can't decrement count for object") |