summaryrefslogtreecommitdiffstats
path: root/test/istore.c
diff options
context:
space:
mode:
Diffstat (limited to 'test/istore.c')
-rw-r--r--test/istore.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/test/istore.c b/test/istore.c
index ec7542a..68668d8 100644
--- a/test/istore.c
+++ b/test/istore.c
@@ -529,9 +529,9 @@ test_sparse(hid_t f, const char *prefix, size_t nblocks,
if((mspace=H5Screate_simple(ndims,size,NULL)) < 0) TEST_ERROR;
for (ctr=0; ctr<nblocks; ctr++) {
- offset[0] = (hsize_t)(HDrandom() % (TEST_SPARSE_SIZE-nx));
- offset[1] = (hsize_t)(HDrandom() % (TEST_SPARSE_SIZE-ny));
- offset[2] = (hsize_t)(HDrandom() % (TEST_SPARSE_SIZE-nz));
+ offset[0] = (hsize_t)(HDrandom() % (int)(TEST_SPARSE_SIZE-nx));
+ offset[1] = (hsize_t)(HDrandom() % (int)(TEST_SPARSE_SIZE-ny));
+ offset[2] = (hsize_t)(HDrandom() % (int)(TEST_SPARSE_SIZE-nz));
/* Select region in file dataspace */
if(H5Sselect_hyperslab(fspace,H5S_SELECT_SET,offset,NULL,size,NULL) < 0) TEST_ERROR;