diff options
author | Neil Fortner <nfortne2@hdfgroup.org> | 2019-11-28 04:48:01 (GMT) |
---|---|---|
committer | Neil Fortner <nfortne2@hdfgroup.org> | 2019-12-06 22:32:11 (GMT) |
commit | a5091c0013967e7d0ac3cf0426f87c53a8876445 (patch) | |
tree | 8b1b955edacc7c9c0a5a787f18001b9e97c4556a /src/H5VLint.c | |
parent | 07c337dc57aa062a5a9467ef79455e6da3f827e3 (diff) | |
download | hdf5-a5091c0013967e7d0ac3cf0426f87c53a8876445.zip hdf5-a5091c0013967e7d0ac3cf0426f87c53a8876445.tar.gz hdf5-a5091c0013967e7d0ac3cf0426f87c53a8876445.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; |