diff options
author | Quincey Koziol <koziol@hdfgroup.org> | 2002-06-19 16:08:27 (GMT) |
---|---|---|
committer | Quincey Koziol <koziol@hdfgroup.org> | 2002-06-19 16:08:27 (GMT) |
commit | 8bb096b6977a90df82ca3d32287aa2a7abeb5510 (patch) | |
tree | c63e215da154603f99afff0b9d9b31149a9c2e5c /src/H5Fistore.c | |
parent | c0c4219b5084ebcbcfe56bb807ece294f2f4f4aa (diff) | |
download | hdf5-8bb096b6977a90df82ca3d32287aa2a7abeb5510.zip hdf5-8bb096b6977a90df82ca3d32287aa2a7abeb5510.tar.gz hdf5-8bb096b6977a90df82ca3d32287aa2a7abeb5510.tar.bz2 |
[svn-r5675] Purpose:
Code cleanup
Description:
Removed more compiler warnings, etc.
Platforms tested:
Linux 2.2.x (eirene) w/parallel
Diffstat (limited to 'src/H5Fistore.c')
-rw-r--r-- | src/H5Fistore.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/src/H5Fistore.c b/src/H5Fistore.c index cbfa1bf..ce29bbf 100644 --- a/src/H5Fistore.c +++ b/src/H5Fistore.c @@ -2317,7 +2317,8 @@ H5F_istore_allocate(H5F_t *f, hid_t dxpl_id, const H5O_layout_t *layout, } /* Allocate chunk buffer for processes to use when writing fill values */ - if (NULL==(chunk = H5MM_malloc(chunk_size))) + H5_CHECK_OVERFLOW(chunk_size,hsize_t,size_t); + if (NULL==(chunk = H5MM_malloc((size_t)chunk_size))) HGOTO_ERROR(H5E_RESOURCE, H5E_NOSPACE, FAIL, "memory allocation failed for chunk"); /* Fill the chunk with the proper values */ @@ -2326,12 +2327,12 @@ H5F_istore_allocate(H5F_t *f, hid_t dxpl_id, const H5O_layout_t *layout, * Replicate the fill value throughout the chunk. */ assert(0==chunk_size % fill->size); - H5V_array_fill(chunk, fill->buf, fill->size, chunk_size/fill->size); + H5V_array_fill(chunk, fill->buf, fill->size, (size_t)chunk_size/fill->size); } else { /* * No fill value was specified, assume all zeros. */ - HDmemset (chunk, 0, chunk_size); + HDmemset (chunk, 0, (size_t)chunk_size); } /* end else */ /* Retrieve up MPI parameters */ @@ -2359,7 +2360,7 @@ H5F_istore_allocate(H5F_t *f, hid_t dxpl_id, const H5O_layout_t *layout, /* Round-robin write the chunks out from only one process */ if(mpi_round==mpi_rank) { - if (H5F_block_write(f, H5FD_MEM_DRAW, udata.addr, udata.key.nbytes, dxpl_id, chunk)<0) + if (H5F_block_write(f, H5FD_MEM_DRAW, udata.addr, (hsize_t)udata.key.nbytes, dxpl_id, chunk)<0) HGOTO_ERROR(H5E_IO, H5E_WRITEERROR, FAIL, "unable to write raw data to file"); } /* end if */ mpi_round=(++mpi_round)%mpi_size; |