summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorQuincey Koziol <koziol@hdfgroup.org>2000-06-06 18:53:16 (GMT)
committerQuincey Koziol <koziol@hdfgroup.org>2000-06-06 18:53:16 (GMT)
commitf16251c705ca8b62d3a7dd015941093e68ed8c6f (patch)
treee84a7ec3ce7ffa3eb110abcae8ad1492892b7a5d
parentae635d079e9a473471947652602babb016d8ade4 (diff)
downloadhdf5-f16251c705ca8b62d3a7dd015941093e68ed8c6f.zip
hdf5-f16251c705ca8b62d3a7dd015941093e68ed8c6f.tar.gz
hdf5-f16251c705ca8b62d3a7dd015941093e68ed8c6f.tar.bz2
[svn-r2344] Fixed a bug where memory was being inspected after being free'd, found only
in Windows.
-rw-r--r--src/H5AC.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/H5AC.c b/src/H5AC.c
index 00ecf0e..f8acbb3 100644
--- a/src/H5AC.c
+++ b/src/H5AC.c
@@ -425,6 +425,8 @@ H5AC_flush(H5F_t *f, const H5AC_class_t *type, haddr_t addr, hbool_t destroy)
continue;
#endif
if (!type || type == (*info)->type) {
+ H5AC_subid_t type_id=(*info)->type->id; /* Remember this for later */
+
flush = (*info)->type->flush;
status = (flush)(f, destroy, (*info)->addr, (*info));
if (status < 0) {
@@ -432,7 +434,7 @@ H5AC_flush(H5F_t *f, const H5AC_class_t *type, haddr_t addr, hbool_t destroy)
HRETURN_ERROR(H5E_CACHE, H5E_CANTFLUSH, FAIL,
"unable to flush cache");
}
- cache->diagnostics[(*info)->type->id].nflushes++;
+ cache->diagnostics[type_id].nflushes++;
if (destroy)
(*info)= NULL;
}