summaryrefslogtreecommitdiffstats
path: root/src/H5FAhdr.c
diff options
context:
space:
mode:
authorQuincey Koziol <koziol@hdfgroup.org>2015-06-18 00:58:49 (GMT)
committerQuincey Koziol <koziol@hdfgroup.org>2015-06-18 00:58:49 (GMT)
commitf30ab55f41296667eab0b273132ffc20c4323717 (patch)
tree2fd6a85b7c15e3505e308e21b41e67297cc58508 /src/H5FAhdr.c
parent6e9e9e0dd200979642de8d2a2bce2f66f9728237 (diff)
downloadhdf5-f30ab55f41296667eab0b273132ffc20c4323717.zip
hdf5-f30ab55f41296667eab0b273132ffc20c4323717.tar.gz
hdf5-f30ab55f41296667eab0b273132ffc20c4323717.tar.bz2
[svn-r27237] Description:
Merge v3 metadata cache changes to trunk. Yay! :-) Tested on: MacOSX/64 10.10.3 (amazon) w/serial & parallel Linux/32 2.6.x (jam) w/serial & parallel (daily tested on branch)
Diffstat (limited to 'src/H5FAhdr.c')
-rw-r--r--src/H5FAhdr.c13
1 files changed, 11 insertions, 2 deletions
diff --git a/src/H5FAhdr.c b/src/H5FAhdr.c
index 23c20bc..9083a52 100644
--- a/src/H5FAhdr.c
+++ b/src/H5FAhdr.c
@@ -408,16 +408,25 @@ END_FUNC(PKG) /* end H5FA__hdr_modified() */
BEGIN_FUNC(PKG, ERR,
H5FA_hdr_t *, NULL, NULL,
H5FA__hdr_protect(H5F_t *f, hid_t dxpl_id, haddr_t fa_addr, void *ctx_udata,
- H5AC_protect_t rw))
+ unsigned flags))
/* Local variables */
+ H5FA_hdr_cache_ud_t udata; /* User data for cache callbacks */
/* Sanity check */
HDassert(f);
HDassert(H5F_addr_defined(fa_addr));
+ /* only the H5AC__READ_ONLY_FLAG is permitted */
+ HDassert((flags & (unsigned)(~H5AC__READ_ONLY_FLAG)) == 0);
+
+ /* Set up user data for cache callbacks */
+ udata.f = f;
+ udata.addr = fa_addr;
+ udata.ctx_udata = ctx_udata;
+
/* Protect the header */
- if(NULL == (ret_value = (H5FA_hdr_t *)H5AC_protect(f, dxpl_id, H5AC_FARRAY_HDR, fa_addr, ctx_udata, rw)))
+ if(NULL == (ret_value = (H5FA_hdr_t *)H5AC_protect(f, dxpl_id, H5AC_FARRAY_HDR, fa_addr, &udata, flags)))
H5E_THROW(H5E_CANTPROTECT, "unable to protect fixed array header, address = %llu", (unsigned long long)fa_addr)
CATCH