summaryrefslogtreecommitdiffstats
path: root/src/H5Dnone.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/H5Dnone.c')
-rw-r--r--src/H5Dnone.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/H5Dnone.c b/src/H5Dnone.c
index be421b6..09e781e 100644
--- a/src/H5Dnone.c
+++ b/src/H5Dnone.c
@@ -242,7 +242,7 @@ H5D__none_idx_iterate(const H5D_chk_idx_info_t *idx_info,
unsigned u; /* Local index variable */
int curr_dim; /* Current rank */
hsize_t idx; /* Array index of chunk */
- int ret_value = -1; /* Return value */
+ int ret_value = H5_ITER_CONT; /* Return value */
FUNC_ENTER_STATIC_NOERR
@@ -266,7 +266,7 @@ H5D__none_idx_iterate(const H5D_chk_idx_info_t *idx_info,
HDassert(ndims > 0);
/* Iterate over all the chunks in the dataset's dataspace */
- for(u = 0; u < idx_info->layout->nchunks; u++) {
+ for(u = 0; u < idx_info->layout->nchunks && ret_value == H5_ITER_CONT; u++) {
/* Calculate the index of this chunk */
idx = H5VM_array_offset_pre(ndims, idx_info->layout->max_down_chunks, chunk_rec.scaled);