summaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
authorBinh-Minh Ribler <bmribler@hdfgroup.org>2019-03-20 19:03:48 (GMT)
committerBinh-Minh Ribler <bmribler@hdfgroup.org>2019-03-20 19:03:48 (GMT)
commit7add52ff4f2443357648d53d52add274d1b18b5f (patch)
tree7bfeb541f99b73c95288477e5fd1b84caef8bb01 /test
parent55d1931dc6af168adc3804586a0da22287b29187 (diff)
downloadhdf5-7add52ff4f2443357648d53d52add274d1b18b5f.zip
hdf5-7add52ff4f2443357648d53d52add274d1b18b5f.tar.gz
hdf5-7add52ff4f2443357648d53d52add274d1b18b5f.tar.bz2
Fixed HDFFV-10210 and HDFFV-10587
Description: - Added parameter validation (HDFFV-10210) - Added detection of division by zero (HDFFV-10587 - CVE-2018-17438) - Fixed typos in various tests Platforms tested: Linux/64 (jelly) Linux/64 (platypus) Darwin (osx1011test)
Diffstat (limited to 'test')
-rw-r--r--test/tid.c15
-rw-r--r--test/titerate.c2
2 files changed, 16 insertions, 1 deletions
diff --git a/test/tid.c b/test/tid.c
index 8a27c3b..d2bcdc4 100644
--- a/test/tid.c
+++ b/test/tid.c
@@ -224,6 +224,21 @@ static int basic_id_test(void)
goto out;
H5E_END_TRY
+ /* Test that H5Itype_exists cannot be called on library types because
+ * it is a public function
+ */
+ H5E_BEGIN_TRY
+ err = H5Itype_exists(H5I_GROUP);
+ if(err >= 0)
+ goto out;
+ H5E_END_TRY
+
+ H5E_BEGIN_TRY
+ err = H5Itype_exists(H5I_ATTR);
+ if(err >= 0)
+ goto out;
+ H5E_END_TRY
+
return 0;
out:
diff --git a/test/titerate.c b/test/titerate.c
index 87ddfb8..5fad1b4 100644
--- a/test/titerate.c
+++ b/test/titerate.c
@@ -946,7 +946,7 @@ find_err_msg_cb(unsigned n, const H5E_error2_t *err_desc, void *_client_data)
if (searched_err == NULL)
return -1;
-
+
/* If the searched error message is found, stop the iteration */
if (err_desc->desc != NULL && strcmp(err_desc->desc, searched_err->message) == 0)
{