diff options
author | Quincey Koziol <koziol@hdfgroup.org> | 2016-07-18 00:18:42 (GMT) |
---|---|---|
committer | Quincey Koziol <koziol@hdfgroup.org> | 2016-07-18 00:18:42 (GMT) |
commit | bb19817c9fd5d46cdc1ab5a396f38f0561dfa167 (patch) | |
tree | 69498cabeabf6f68faa23b835e24cb7ef4f80563 /tools/h5jam | |
parent | c8f4641507bf4ca85c70c39c786c07f8ef4a24ed (diff) | |
download | hdf5-bb19817c9fd5d46cdc1ab5a396f38f0561dfa167.zip hdf5-bb19817c9fd5d46cdc1ab5a396f38f0561dfa167.tar.gz hdf5-bb19817c9fd5d46cdc1ab5a396f38f0561dfa167.tar.bz2 |
[svn-r30189] Description:
Clean up more warnings: drop the warning count from ~1310 down to ~940,
with only 31 types of warnings in 148 files (down from 38 types in 167 files).
Tested on:
MacOSX/64 10.11.5 (amazon) w/serial & parallel
(h5committest forthcoming)
Diffstat (limited to 'tools/h5jam')
-rw-r--r-- | tools/h5jam/h5unjam.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/tools/h5jam/h5unjam.c b/tools/h5jam/h5unjam.c index 8e4eac4..8f88398 100644 --- a/tools/h5jam/h5unjam.c +++ b/tools/h5jam/h5unjam.c @@ -347,17 +347,19 @@ done: * Returns 0 on success, -1 on failure. */ herr_t -copy_to_file( FILE *infid, FILE *ofid, ssize_t _where, ssize_t how_much ) +copy_to_file( FILE *infid, FILE *ofid, ssize_t _where, ssize_t show_much ) { static char buf[COPY_BUF_SIZE]; + size_t how_much; off_t where = (off_t)_where; off_t to; off_t from; herr_t ret_value = 0; /* nothing to copy */ - if(how_much <= 0) + if(show_much <= 0) goto done; + how_much = (size_t)show_much; /* rewind */ HDfseek(infid, 0L, 0); @@ -392,8 +394,8 @@ copy_to_file( FILE *infid, FILE *ofid, ssize_t _where, ssize_t how_much ) /* Update positions/size */ how_much -= bytes_read; - from += bytes_read; - to += bytes_read; + from += (off_t)bytes_read; + to += (off_t)bytes_read; /* Write nchars bytes to output file */ bytes_wrote = HDfwrite(buf, (size_t)1, bytes_read, ofid); |