summaryrefslogtreecommitdiffstats
path: root/hl
diff options
context:
space:
mode:
authorAllen Byrne <byrn@hdfgroup.org>2011-05-25 15:27:58 (GMT)
committerAllen Byrne <byrn@hdfgroup.org>2011-05-25 15:27:58 (GMT)
commit44e5d2a1d7a83b8196094a63f7023c514bcdae2a (patch)
tree8d0986bee4124feb1dda054fa1e0158aa1786a1a /hl
parentcada25ba3d21104da4227daf95dba6dd7b4bedaa (diff)
downloadhdf5-44e5d2a1d7a83b8196094a63f7023c514bcdae2a.zip
hdf5-44e5d2a1d7a83b8196094a63f7023c514bcdae2a.tar.gz
hdf5-44e5d2a1d7a83b8196094a63f7023c514bcdae2a.tar.bz2
[svn-r20904] Bring r20871, 20875, 20901, 20903 from trunk.
Tested: local linux
Diffstat (limited to 'hl')
-rw-r--r--hl/src/H5DS.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/hl/src/H5DS.c b/hl/src/H5DS.c
index 432a725..379b220 100644
--- a/hl/src/H5DS.c
+++ b/hl/src/H5DS.c
@@ -813,10 +813,8 @@ herr_t H5DSdetach_scale(hid_t did,
/* same object, reset. we want to detach only for this DIM */
if(did_oi.fileno == tmp_oi.fileno && did_oi.addr == tmp_oi.addr) {
- /* if we found not the last one, copy the last one to replace
- the one which is found */
- if(i < nelmts-1)
- dsbuf[ii] = dsbuf[nelmts-1];
+ /* copy the last one to replace the one which is found */
+ dsbuf[ii] = dsbuf[nelmts-1];
nelmts--;
found_dset=1;
break;