summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorQuincey Koziol <koziol@hdfgroup.org>2000-04-12 22:02:26 (GMT)
committerQuincey Koziol <koziol@hdfgroup.org>2000-04-12 22:02:26 (GMT)
commit43017c3d9aa1f4be6be58e9ace723f7990c816a3 (patch)
tree70e0fafdab49b3e9dbb92b6833e968d020f7200d
parente47b34e54f2886a39cbbcf99d20dd8fbaf77b834 (diff)
downloadhdf5-43017c3d9aa1f4be6be58e9ace723f7990c816a3.zip
hdf5-43017c3d9aa1f4be6be58e9ace723f7990c816a3.tar.gz
hdf5-43017c3d9aa1f4be6be58e9ace723f7990c816a3.tar.bz2
[svn-r2132] Tested H5Screate_simple & H5Sset_extent_simple disallowing
size 0 dimensions without corresponding unlimited dimension.
-rw-r--r--test/th5s.c14
1 files changed, 14 insertions, 0 deletions
diff --git a/test/th5s.c b/test/th5s.c
index e26fe9a..46ddf2b 100644
--- a/test/th5s.c
+++ b/test/th5s.c
@@ -170,6 +170,20 @@ test_h5s_basic(void)
VERIFY(dset1, FAIL, "H5Dopen");
ret = H5Fclose(fid1);
CHECK_I(ret, "H5Fclose");
+
+ /* Verify that incorrect dimensions don't work */
+ dims1[0]=0;
+ sid1 = H5Screate_simple(SPACE1_RANK, dims1, NULL);
+ VERIFY(sid1, FAIL, "H5Screate_simple");
+
+ sid1 = H5Screate(H5S_SIMPLE);
+ CHECK(sid1, FAIL, "H5Screate");
+
+ ret = H5Sset_extent_simple(sid1,SPACE1_RANK,dims1,NULL);
+ VERIFY(ret, FAIL, "H5Sset_extent_simple");
+
+ ret = H5Sclose(sid1);
+ CHECK_I(ret, "H5Sclose");
} /* test_h5s_basic() */
/****************************************************************