summaryrefslogtreecommitdiffstats
path: root/c++
diff options
context:
space:
mode:
authorLarry Knox <lrknox@hdfgroup.org>2021-03-10 21:51:21 (GMT)
committerGitHub <noreply@github.com>2021-03-10 21:51:21 (GMT)
commitbf4399bd25eef9886dab5dcb115e2e439e3a2ac9 (patch)
treeb54cb4ef5e607a222a5589400976c0a4e06e4821 /c++
parente5a2d01cd9e3b5fd34d265fe281f638316894f7a (diff)
downloadhdf5-bf4399bd25eef9886dab5dcb115e2e439e3a2ac9.zip
hdf5-bf4399bd25eef9886dab5dcb115e2e439e3a2ac9.tar.gz
hdf5-bf4399bd25eef9886dab5dcb115e2e439e3a2ac9.tar.bz2
Hdf5 merge issue 435 v110 (#462)
* close #195. (#196) * Update HDF5PluginMacros.cmake * Update HDF5PluginMacros.cmake * Modify temporary rpath for testing in java example scripts. (#230) * Fix undefined left shifting of negative numbers (#338) Undefined Bahavior Sanitizer errored here about left shifting negative numbers. * Update license url (#332) * Modify temporary rpath for testing in java example scripts. * Update URL in source file Copyright headers for web copy of COPYING file - src and test directories. * Fixed clang-tidy readability-misleading-indentation warnings (#427) * Fixed clang-tidy readability-misleading-indentation warnings * Reformatted src/H5Zscaleoffset.c with clang v10.0.1. Co-authored-by: Larry Knox <lrknox@hdfgroup.org> * Fixed clang-tidy readability-redundant-control-flow warnings (#428) * Fixed clang-tidy readability-redundant-control-flow warnings Just removed useless trailing return statements. * Removed blank lines from h5diffgentest.c with clang-format v10.0.1. Co-authored-by: Larry Knox <lrknox@hdfgroup.org> * Removed bad function pointer casts (#434) * Removed bad function pointer casts In one case fixed the actual function signature to be correct. * Reformat source with clang v10.0.1. Co-authored-by: Larry Knox <lrknox@hdfgroup.org> * fix block coordinate printing example (#437) Co-authored-by: H. Joe Lee <hyoklee@hdfgroup.org> Co-authored-by: Sean McBride <sean@rogue-research.com> Co-authored-by: Mike Smith <grimbough@gmail.com>
Diffstat (limited to 'c++')
-rw-r--r--c++/test/dsets.cpp14
-rw-r--r--c++/test/tfilter.cpp36
2 files changed, 25 insertions, 25 deletions
diff --git a/c++/test/dsets.cpp b/c++/test/dsets.cpp
index 45dd9cb..dbf9d25 100644
--- a/c++/test/dsets.cpp
+++ b/c++/test/dsets.cpp
@@ -398,13 +398,13 @@ test_tconv(H5File &file)
/* This message derives from H5Z */
const H5Z_class2_t H5Z_BOGUS[1] = {{
- H5Z_CLASS_T_VERS, /* H5Z_class_t version number */
- H5Z_FILTER_BOGUS, /* Filter id number */
- 1, 1, /* Encode and decode enabled */
- "bogus", /* Filter name for debugging */
- NULL, /* The "can apply" callback */
- NULL, /* The "set local" callback */
- (H5Z_func_t)filter_bogus, /* The actual filter function */
+ H5Z_CLASS_T_VERS, /* H5Z_class_t version number */
+ H5Z_FILTER_BOGUS, /* Filter id number */
+ 1, 1, /* Encode and decode enabled */
+ "bogus", /* Filter name for debugging */
+ NULL, /* The "can apply" callback */
+ NULL, /* The "set local" callback */
+ filter_bogus, /* The actual filter function */
}};
/*-------------------------------------------------------------------------
diff --git a/c++/test/tfilter.cpp b/c++/test/tfilter.cpp
index 1ded033..2df88b2 100644
--- a/c++/test/tfilter.cpp
+++ b/c++/test/tfilter.cpp
@@ -49,20 +49,18 @@ static herr_t test_filter_internal(hid_t fid, const char *name, hid_t dcpl,
/* Temporary filter IDs used for testing */
const int H5Z_FILTER_BOGUS = 305;
-#if 0 // H5_ATTR_UNUSED variables caused warning, so duplicated below with NULL instead
-static size_t filter_bogus(unsigned int flags, size_t cd_nelmts,
- const unsigned int *cd_values, size_t nbytes, size_t *buf_size, void **buf);
-#endif
-static size_t filter_bogus(size_t nbytes);
+static size_t filter_bogus(unsigned int flags, size_t cd_nelmts, const unsigned int *cd_values, size_t nbytes,
+ size_t *buf_size, void **buf);
+
/* This message derives from H5Z */
const H5Z_class2_t H5Z_BOGUS[1] = {{
- H5Z_CLASS_T_VERS, /* H5Z_class_t version */
- H5Z_FILTER_BOGUS, /* Filter id number */
- 1, 1, /* Encoding and decoding enabled */
- "bogus", /* Filter name for debugging */
- NULL, /* The "can apply" callback */
- NULL, /* The "set local" callback */
- (H5Z_func_t)filter_bogus, /* The actual filter function */
+ H5Z_CLASS_T_VERS, /* H5Z_class_t version */
+ H5Z_FILTER_BOGUS, /* Filter id number */
+ 1, 1, /* Encoding and decoding enabled */
+ "bogus", /* Filter name for debugging */
+ NULL, /* The "can apply" callback */
+ NULL, /* The "set local" callback */
+ filter_bogus, /* The actual filter function */
}};
/*-------------------------------------------------------------------------
@@ -79,13 +77,15 @@ const H5Z_class2_t H5Z_BOGUS[1] = {{
*-------------------------------------------------------------------------
*/
static size_t
-#if 0 // H5_ATTR_UNUSED variables caused warning, so duplicated below with NULL instead
-filter_bogus(unsigned int H5_ATTR_UNUSED flags, size_t H5_ATTR_UNUSED cd_nelmts,
- const unsigned int H5_ATTR_UNUSED *cd_values, size_t nbytes,
- size_t H5_ATTR_UNUSED *buf_size, void H5_ATTR_UNUSED **buf)
-#endif
-filter_bogus(size_t nbytes)
+filter_bogus(unsigned int flags, size_t cd_nelmts, const unsigned int *cd_values, size_t nbytes,
+ size_t *buf_size, void **buf)
{
+ (void)flags;
+ (void)cd_nelmts;
+ (void)cd_values;
+ (void)buf_size;
+ (void)buf;
+
return nbytes;
}