diff options
author | Quincey Koziol <koziol@hdfgroup.org> | 2007-05-29 20:02:34 (GMT) |
---|---|---|
committer | Quincey Koziol <koziol@hdfgroup.org> | 2007-05-29 20:02:34 (GMT) |
commit | bdcbada3f282774f709e17990dc7f77b24919950 (patch) | |
tree | f2f1264f0a3c7ac08b78eb314358ce1ee62aa5a5 /src/H5FDcore.c | |
parent | 7b0fa3950e74ea0c9bfe3baa07a48e2d451ebab5 (diff) | |
download | hdf5-bdcbada3f282774f709e17990dc7f77b24919950.zip hdf5-bdcbada3f282774f709e17990dc7f77b24919950.tar.gz hdf5-bdcbada3f282774f709e17990dc7f77b24919950.tar.bz2 |
[svn-r13814] Description:
Change back to clearing memory buffers by default, but give users option
to disable this, for performance reasons (--disable-clear-file-buffers).
Also, add configure option (--enable-using-memchecker) to conveniently
control making the library "play nice" with memory checking tools like valgrind
and purify.
Tested on:
Mac OS X/32 10.4.9 (amazon)
FreeBSD/32 6.2 (duty)
Linux/32 2.6 (kagiso)
Diffstat (limited to 'src/H5FDcore.c')
-rw-r--r-- | src/H5FDcore.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/H5FDcore.c b/src/H5FDcore.c index dba902b..4c468b6 100644 --- a/src/H5FDcore.c +++ b/src/H5FDcore.c @@ -826,9 +826,9 @@ H5FD_core_write(H5FD_t *_file, H5FD_mem_t UNUSED type, hid_t UNUSED dxpl_id, had x = H5MM_malloc(new_eof); else x = H5MM_realloc(file->mem, new_eof); -#ifdef H5_USING_PURIFY +#ifdef H5_CLEAR_MEMORY HDmemset(x + file->eof, 0, (size_t)(new_eof - file->eof)); -#endif /* H5_USING_PURIFY */ +#endif /* H5_CLEAR_MEMORY */ if (!x) HGOTO_ERROR(H5E_RESOURCE, H5E_NOSPACE, FAIL, "unable to allocate memory block") file->mem = x; |