summaryrefslogtreecommitdiffstats
path: root/src/H5Dsingle.c
diff options
context:
space:
mode:
authorDavid Young <dyoung@hdfgroup.org>2020-06-12 16:24:27 (GMT)
committerDavid Young <dyoung@hdfgroup.org>2020-06-12 16:24:27 (GMT)
commit625ef85fe56d8265989e8c1ed32331064012a068 (patch)
tree814195dc9c8e3620e9a85adc6e0e4e7569563485 /src/H5Dsingle.c
parentff43cd3631eaa13886933db3030728fc374c7123 (diff)
downloadhdf5-625ef85fe56d8265989e8c1ed32331064012a068.zip
hdf5-625ef85fe56d8265989e8c1ed32331064012a068.tar.gz
hdf5-625ef85fe56d8265989e8c1ed32331064012a068.tar.bz2
Avoid leaving a v1 B-tree used as a chunk index in a bad state
that makes assertions fail. Add an optional `close` method to the `H5D_chunk_ops_t`, and use that to release "holds" on metadata cache (MDC) entries. For extensible arrays and v2 B-trees, use the existing `dest`(roy) method to implement `close`. For v1 B-trees and other chunk indices, don't provide `close`: we cannot safely close the v1 B-tree index, and the other indices don't have a meaningful presence in the MDC. Revert my first attempt at making v1 B-tree chunk indices closeable with `dest`. Put my comment about the stopgap fix for VFD SWMR at the right place in src/H5Dchunk.c.
Diffstat (limited to 'src/H5Dsingle.c')
-rw-r--r--src/H5Dsingle.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/H5Dsingle.c b/src/H5Dsingle.c
index 33274bb..3fa9bc2 100644
--- a/src/H5Dsingle.c
+++ b/src/H5Dsingle.c
@@ -97,7 +97,8 @@ const H5D_chunk_ops_t H5D_COPS_SINGLE[1] = {{
H5D__single_idx_size, /* size */
H5D__single_idx_reset, /* reset */
H5D__single_idx_dump, /* dump */
- NULL /* destroy */
+ NULL, /* destroy */
+ NULL /* close */
}};