summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRaymond Lu <songyulu@hdfgroup.org>2002-06-27 19:04:22 (GMT)
committerRaymond Lu <songyulu@hdfgroup.org>2002-06-27 19:04:22 (GMT)
commit9defa2db2aa980c181bccc17b957742961a77635 (patch)
tree76add8891122e757852272f8dfe0034f36f2a910
parentc973d3145d281cae9cb0520dd5844375f822c0ec (diff)
downloadhdf5-9defa2db2aa980c181bccc17b957742961a77635.zip
hdf5-9defa2db2aa980c181bccc17b957742961a77635.tar.gz
hdf5-9defa2db2aa980c181bccc17b957742961a77635.tar.bz2
[svn-r5724]
Purpose: bug fix Description: In H5HG_remove, heap object header wasn't included for size("need" in H5HG_remove). Solution: Added heap object header size in. Platforms tested: Linux 2.2(eirene).
-rw-r--r--src/H5HG.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/H5HG.c b/src/H5HG.c
index a3fb554..283aba5 100644
--- a/src/H5HG.c
+++ b/src/H5HG.c
@@ -874,9 +874,8 @@ H5HG_remove (H5F_t *f, H5HG_t *hobj)
assert (hobj->idx>0 && hobj->idx<heap->nalloc);
assert (heap->obj[hobj->idx].begin);
obj_start = heap->obj[hobj->idx].begin;
- need = H5HG_ALIGN(heap->obj[hobj->idx].size); /* should this include the
- * object header size? -rpm
- */
+ /* Include object header size */
+ need = H5HG_ALIGN(heap->obj[hobj->idx].size)+H5HG_SIZEOF_OBJHDR(f);
/* Move the new free space to the end of the heap */
for (i=0; i<heap->nalloc; i++) {