diff options
author | Quincey Koziol <koziol@hdfgroup.org> | 2004-04-19 20:23:15 (GMT) |
---|---|---|
committer | Quincey Koziol <koziol@hdfgroup.org> | 2004-04-19 20:23:15 (GMT) |
commit | c39de522e9559c382b7e705e7cb68fde263837b2 (patch) | |
tree | 6840c45248d44b61186f4d1d90f0f8c4ae6f5edd /src/H5Distore.c | |
parent | 793f7c72dcf3a9875f5162091f4047e6caed6de5 (diff) | |
download | hdf5-c39de522e9559c382b7e705e7cb68fde263837b2.zip hdf5-c39de522e9559c382b7e705e7cb68fde263837b2.tar.gz hdf5-c39de522e9559c382b7e705e7cb68fde263837b2.tar.bz2 |
[svn-r8394] Purpose:
Code optimization
Description:
Avoid clearing the error stack unless necessary.
Platforms tested:
Solaris 2.7 (arabica)
FreeBSD 4.9 (sleipnir)
too minor to require h5committest
Diffstat (limited to 'src/H5Distore.c')
-rw-r--r-- | src/H5Distore.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/H5Distore.c b/src/H5Distore.c index f602689..17a4be9 100644 --- a/src/H5Distore.c +++ b/src/H5Distore.c @@ -1425,7 +1425,6 @@ H5F_istore_lock(H5F_t *f, const H5D_dxpl_cache_t *dxpl_cache, hid_t dxpl_id, con udata.mesg = *layout; udata.addr = HADDR_UNDEF; status = H5B_find (f, dxpl_id, H5B_ISTORE, layout->addr, &udata); - H5E_clear (); if (status>=0 && H5F_addr_defined(udata.addr)) { size_t chunk_alloc=0; /*allocated chunk size */ @@ -1448,6 +1447,9 @@ H5F_istore_lock(H5F_t *f, const H5D_dxpl_cache_t *dxpl_cache, hid_t dxpl_id, con } else { H5D_fill_value_t fill_status; + /* Clear the error stack from not finding the chunk on disk */ + H5E_clear(); + /* Chunk size on disk isn't [likely] the same size as the final chunk * size in memory, so allocate memory big enough. */ if (NULL==(chunk = H5MM_malloc (chunk_size))) |