diff options
author | Neil Fortner <nfortne2@hdfgroup.org> | 2019-12-01 00:44:02 (GMT) |
---|---|---|
committer | Neil Fortner <nfortne2@hdfgroup.org> | 2019-12-01 00:44:02 (GMT) |
commit | 0772b975d1d2bfa15aedeb4b6e2c2aac78c61a2f (patch) | |
tree | 9df3e9cafae901d462a14a6689caa93507a515e7 /src/H5VLnative_file.c | |
parent | 648073ea8e4cd1b3543073e7b1cbb4bd7e469b44 (diff) | |
parent | 40b2658b4b266b4dc65ec3db2897e0aaf54f8e42 (diff) | |
download | hdf5-0772b975d1d2bfa15aedeb4b6e2c2aac78c61a2f.zip hdf5-0772b975d1d2bfa15aedeb4b6e2c2aac78c61a2f.tar.gz hdf5-0772b975d1d2bfa15aedeb4b6e2c2aac78c61a2f.tar.bz2 |
Merge pull request #2063 in HDFFV/hdf5 from ~NFORTNE2/hdf5_naf:vol_file_cmp to develop
* commit '40b2658b4b266b4dc65ec3db2897e0aaf54f8e42':
Fix missing free in H5T__ref_mem_read()
Fix bugs in H5VL file comparison code. Add short circuit success to H5VL_cmp_connector_cls().
Implement file comparison VOL callback. Other changes to allow references to work with non-native connectors. There is a bug somewhere.
Diffstat (limited to 'src/H5VLnative_file.c')
-rw-r--r-- | src/H5VLnative_file.c | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/src/H5VLnative_file.c b/src/H5VLnative_file.c index 3bda0b8..588d59f 100644 --- a/src/H5VLnative_file.c +++ b/src/H5VLnative_file.c @@ -418,6 +418,19 @@ H5VL__native_file_specific(void *obj, H5VL_file_specific_t specific_type, break; } + /* Check if two files are the same */ + case H5VL_FILE_IS_EQUAL: + { + H5F_t *file2 = (H5F_t *)HDva_arg(arguments, void *); + hbool_t *is_equal = HDva_arg(arguments, hbool_t *); + + if(!obj || !file2) + *is_equal = FALSE; + else + *is_equal = (((H5F_t *)obj)->shared == file2->shared); + break; + } + default: HGOTO_ERROR(H5E_VOL, H5E_UNSUPPORTED, FAIL, "invalid specific operation") } /* end switch */ |