diff options
author | Quincey Koziol <koziol@hdfgroup.org> | 2011-07-21 14:50:59 (GMT) |
---|---|---|
committer | Quincey Koziol <koziol@hdfgroup.org> | 2011-07-21 14:50:59 (GMT) |
commit | 9d7db150203eebb96360275c1c8fc5b482d31182 (patch) | |
tree | 07e713624b7966413743e2142b60f0de8df1a868 /src/H5SMcache.c | |
parent | 08bb61054759d30c048af7baf1ca144b93ac9ce0 (diff) | |
download | hdf5-9d7db150203eebb96360275c1c8fc5b482d31182.zip hdf5-9d7db150203eebb96360275c1c8fc5b482d31182.tar.gz hdf5-9d7db150203eebb96360275c1c8fc5b482d31182.tar.bz2 |
[svn-r21135] Description:
More code cleanups to reduce coupling with the H5F package.
Tested on:
FreeBSD/32 8.2 (loyalty) w/gcc4.6, w/C++ & FORTRAN, in debug mode
FreeBSD/64 8.2 (freedom) w/gcc4.6, w/C++ & FORTRAN, in debug mode
Linux/32 2.6 (jam) w/PGI compilers, w/default API=1.8.x,
w/C++ & FORTRAN, w/threadsafe, in debug mode
Linux/64-amd64 2.6 (koala) w/Intel compilers, w/default API=1.6.x,
w/C++ & FORTRAN, in production mode
Solaris/32 2.10 (linew) w/deprecated symbols disabled, w/C++ & FORTRAN,
w/szip filter, w/threadsafe, in production mode
Linux/PPC 2.6 (heiwa) w/C++ & FORTRAN, w/threadsafe, in debug mode
Mac OS X/32 10.6.8 (amazon) in debug mode
Diffstat (limited to 'src/H5SMcache.c')
-rw-r--r-- | src/H5SMcache.c | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/src/H5SMcache.c b/src/H5SMcache.c index 1511fd0..65fc359 100644 --- a/src/H5SMcache.c +++ b/src/H5SMcache.c @@ -17,7 +17,6 @@ /* Module Setup */ /****************/ -#define H5F_PACKAGE /*suppress error about including H5Fpkg */ #define H5SM_PACKAGE /*suppress error about including H5SMpkg */ @@ -25,7 +24,7 @@ /* Headers */ /***********/ #include "H5Eprivate.h" /* Error handling */ -#include "H5Fpkg.h" /* File access */ +#include "H5Fprivate.h" /* File access */ #include "H5FLprivate.h" /* Free Lists */ #include "H5MFprivate.h" /* File memory management */ #include "H5MMprivate.h" /* Memory management */ @@ -133,16 +132,16 @@ H5SM_table_load(H5F_t *f, hid_t dxpl_id, haddr_t addr, void UNUSED *udata) /* Verify that we're reading version 0 of the table; this is the only * version defined so far. */ - HDassert(f->shared->sohm_vers == HDF5_SHAREDHEADER_VERSION); + HDassert(H5F_SOHM_VERS(f) == HDF5_SHAREDHEADER_VERSION); /* Allocate space for the master table in memory */ if(NULL == (table = H5FL_CALLOC(H5SM_master_table_t))) HGOTO_ERROR(H5E_SOHM, H5E_NOSPACE, NULL, "memory allocation failed") /* Read number of indexes and version from file superblock */ - table->num_indexes = f->shared->sohm_nindexes; + table->num_indexes = H5F_SOHM_NINDEXES(f); - HDassert(addr == f->shared->sohm_addr); + HDassert(addr == H5F_SOHM_ADDR(f)); HDassert(addr != HADDR_UNDEF); HDassert(table->num_indexes > 0); @@ -273,7 +272,7 @@ H5SM_table_flush(H5F_t *f, hid_t dxpl_id, hbool_t destroy, haddr_t addr, H5SM_ma /* Verify that we're writing version 0 of the table; this is the only * version defined so far. */ - HDassert(f->shared->sohm_vers == HDF5_SHAREDHEADER_VERSION); + HDassert(H5F_SOHM_VERS(f) == HDF5_SHAREDHEADER_VERSION); /* Wrap the local buffer for serialized header info */ if(NULL == (wb = H5WB_wrap(tbl_buf, sizeof(tbl_buf)))) @@ -615,7 +614,7 @@ H5SM_list_flush(H5F_t *f, hid_t dxpl_id, hbool_t destroy, haddr_t addr, H5SM_lis computed_chksum = H5_checksum_metadata(buf, (size_t)(p - buf), 0); UINT32ENCODE(p, computed_chksum); #ifdef H5_CLEAR_MEMORY -HDmemset(p, 0, (list->header->list_size - (p - buf))); +HDmemset(p, 0, (list->header->list_size - (size_t)(p - buf))); #endif /* H5_CLEAR_MEMORY */ /* Write the list to disk */ |