summaryrefslogtreecommitdiffstats
path: root/src/H5B2hdr.c
diff options
context:
space:
mode:
authorQuincey Koziol <koziol@hdfgroup.org>2009-11-15 03:38:58 (GMT)
committerQuincey Koziol <koziol@hdfgroup.org>2009-11-15 03:38:58 (GMT)
commit6d5d4ed1d10498bf776b5a4d41cf2384b4d8fe28 (patch)
treeb629ca68479fa0b8ae9127176975458b77745200 /src/H5B2hdr.c
parent699a5ddec49aad9ee30201a0d89c902a34c7597f (diff)
downloadhdf5-6d5d4ed1d10498bf776b5a4d41cf2384b4d8fe28.zip
hdf5-6d5d4ed1d10498bf776b5a4d41cf2384b4d8fe28.tar.gz
hdf5-6d5d4ed1d10498bf776b5a4d41cf2384b4d8fe28.tar.bz2
[svn-r17893] Descrption:
Remove old shim H5B2 routines from refactoring, rename new routines to old routine names and switch all users of the H5B2 interface back to the old routine names now that the switch to using the more current open -> <operation> -> pattern is used for all the H5B2 code. This is the final change before adding a context to the H5B2 client encode/decode callbacks. Tested on: FreeBSD/32 6.3 (duty) in debug mode FreeBSD/64 6.3 (liberty) 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 (smirom) 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, in production mode Linux/64-ia64 2.6 (cobalt) w/Intel compilers, w/C++ & FORTRAN, in production mode Linux/64-ia64 2.4 (tg-login3) w/parallel, w/FORTRAN, in debug mode Linux/64-amd64 2.6 (abe) w/parallel, w/FORTRAN, in production mode Mac OS X/32 10.6.2 (amazon) in debug mode Mac OS X/32 10.6.2 (amazon) w/C++ & FORTRAN, w/threadsafe, in production mode
Diffstat (limited to 'src/H5B2hdr.c')
-rw-r--r--src/H5B2hdr.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/H5B2hdr.c b/src/H5B2hdr.c
index 31e1674..ec46729 100644
--- a/src/H5B2hdr.c
+++ b/src/H5B2hdr.c
@@ -108,7 +108,7 @@ H5FL_SEQ_DEFINE(H5B2_node_info_t);
*/
herr_t
H5B2_hdr_init(H5F_t *f, H5B2_hdr_t *hdr, const H5B2_create_t *cparam,
- unsigned depth)
+ uint16_t depth)
{
size_t sz_max_nrec; /* Temporary variable for range checking */
unsigned u_max_nrec_size; /* Temporary variable for range checking */
@@ -187,7 +187,7 @@ HDmemset(hdr->page, 0, hdr->node_size);
/* Initialize internal node info */
if(depth > 0) {
- for(u = 1; u < (depth + 1); u++) {
+ for(u = 1; u < (unsigned)(depth + 1); u++) {
sz_max_nrec = H5B2_NUM_INT_REC(hdr, u);
H5_ASSIGN_OVERFLOW(/* To: */ hdr->node_info[u].max_nrec, /* From: */ sz_max_nrec, /* From: */ size_t, /* To: */ unsigned)
HDassert(hdr->node_info[u].max_nrec <= hdr->node_info[u - 1].max_nrec);
@@ -296,11 +296,11 @@ H5B2_hdr_create(H5F_t *f, hid_t dxpl_id, const H5B2_create_t *cparam)
HGOTO_ERROR(H5E_BTREE, H5E_CANTALLOC, HADDR_UNDEF, "allocation failed for B-tree header")
/* Initialize shared B-tree info */
- if(H5B2_hdr_init(f, hdr, cparam, 0) < 0)
+ if(H5B2_hdr_init(f, hdr, cparam, (uint16_t)0) < 0)
HGOTO_ERROR(H5E_BTREE, H5E_CANTINIT, HADDR_UNDEF, "can't create shared B-tree info")
/* Allocate space for the header on disk */
- if(HADDR_UNDEF == (hdr->addr = H5MF_alloc(f, H5FD_MEM_BTREE, dxpl_id, (hsize_t)H5B2_HEADER_SIZE(f))))
+ if(HADDR_UNDEF == (hdr->addr = H5MF_alloc(f, H5FD_MEM_BTREE, dxpl_id, (hsize_t)H5B2_HEADER_SIZE(hdr))))
HGOTO_ERROR(H5E_BTREE, H5E_CANTALLOC, HADDR_UNDEF, "file allocation failed for B-tree header")
/* Cache the new B-tree node */
@@ -520,7 +520,7 @@ H5B2_hdr_free(H5B2_hdr_t *hdr)
unsigned u; /* Local index variable */
/* Destroy free list factories */
- for(u = 0; u < (hdr->depth + 1); u++) {
+ for(u = 0; u < (unsigned)(hdr->depth + 1); u++) {
if(hdr->node_info[u].nat_rec_fac)
if(H5FL_fac_term(hdr->node_info[u].nat_rec_fac) < 0)
HGOTO_ERROR(H5E_BTREE, H5E_CANTRELEASE, FAIL, "can't destroy node's native record block factory")