diff options
author | Neil Fortner <nfortne2@hdfgroup.org> | 2019-11-28 04:48:01 (GMT) |
---|---|---|
committer | David Young <dyoung@hdfgroup.org> | 2020-05-20 14:20:17 (GMT) |
commit | 175a14466cbfb1adf4da0b2e7b539705ab654161 (patch) | |
tree | 17c8ad595b8d6cecae117641d57d44cb581a3c32 /src/H5VLint.c | |
parent | 22ad1bd668de4332c88548591866d1b5e64bd09e (diff) | |
download | hdf5-175a14466cbfb1adf4da0b2e7b539705ab654161.zip hdf5-175a14466cbfb1adf4da0b2e7b539705ab654161.tar.gz hdf5-175a14466cbfb1adf4da0b2e7b539705ab654161.tar.bz2 |
Fix bugs in H5VL file comparison code. Add short circuit success to
H5VL_cmp_connector_cls().
Diffstat (limited to 'src/H5VLint.c')
-rw-r--r-- | src/H5VLint.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/H5VLint.c b/src/H5VLint.c index 733a2b5..284b266 100644 --- a/src/H5VLint.c +++ b/src/H5VLint.c @@ -1639,6 +1639,12 @@ H5VL_cmp_connector_cls(int *cmp_value, const H5VL_class_t *cls1, const H5VL_clas HDassert(cls1); HDassert(cls2); + /* If the pointers are the same the classes are the same */ + if(cls1 == cls2) { + *cmp_value = 0; + HGOTO_DONE(SUCCEED); + } /* end if */ + /* Compare connector "values" */ if(cls1->value < cls2->value) { *cmp_value = -1; |