summaryrefslogtreecommitdiffstats
path: root/src/H5Shyper.c
diff options
context:
space:
mode:
authorQuincey Koziol <koziol@hdfgroup.org>2002-11-01 18:39:20 (GMT)
committerQuincey Koziol <koziol@hdfgroup.org>2002-11-01 18:39:20 (GMT)
commitba751a6a4c23bd0c53625e53f67562f5b4af00b4 (patch)
tree2afd6751bcb6e7eca02611463e16b05e3626287b /src/H5Shyper.c
parent23457df13df32e1db53b3ce36abd2ef7ad6d0494 (diff)
downloadhdf5-ba751a6a4c23bd0c53625e53f67562f5b4af00b4.zip
hdf5-ba751a6a4c23bd0c53625e53f67562f5b4af00b4.tar.gz
hdf5-ba751a6a4c23bd0c53625e53f67562f5b4af00b4.tar.bz2
[svn-r6047] Purpose:
Bug fix & code cleanup Description: Hyperslab code for collapsing dimensions was incorrectly collapsing selections inappropriately when the fastest changing dimension couldn't be collapsed. Also add some more assertions which will make similar bugs easier to find. Solution: Break out of loop earlier. Platforms tested: modi4 (parallel), too small to triple check.
Diffstat (limited to 'src/H5Shyper.c')
-rw-r--r--src/H5Shyper.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/H5Shyper.c b/src/H5Shyper.c
index ad5c53a..3eec64e 100644
--- a/src/H5Shyper.c
+++ b/src/H5Shyper.c
@@ -146,6 +146,8 @@ H5S_hyper_iter_init (const H5S_t *space, size_t elmt_size, H5S_sel_iter_t *sel_i
for(u=space->extent.u.simple.rank-1; u>0; u--) {
if(tdiminfo[u].count==1 && tdiminfo[u].block==mem_size[u])
cont_dim=u;
+ else
+ break;
} /* end for */
/* Check if the regular selection can be "flattened" */