diff options
author | Dana Robinson <43805+derobins@users.noreply.github.com> | 2024-03-09 17:06:10 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-03-09 17:06:10 (GMT) |
commit | 0ea1d7280ba93039cad14faf7b0ed65da20ce563 (patch) | |
tree | 5cd59487a3270224e0aec98606a13cf22706cc26 /src/H5FDdirect.c | |
parent | d4c84f8d0a60e6eedd7288116d203dccf24a0b3a (diff) | |
download | hdf5-0ea1d7280ba93039cad14faf7b0ed65da20ce563.zip hdf5-0ea1d7280ba93039cad14faf7b0ed65da20ce563.tar.gz hdf5-0ea1d7280ba93039cad14faf7b0ed65da20ce563.tar.bz2 |
Clean up off_t usage (#4095)
* Add comments to C++ and Fortran API calls that use off_t
* Remove noise casts for small integers
Diffstat (limited to 'src/H5FDdirect.c')
-rw-r--r-- | src/H5FDdirect.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/H5FDdirect.c b/src/H5FDdirect.c index 08c4a83..49f80d4 100644 --- a/src/H5FDdirect.c +++ b/src/H5FDdirect.c @@ -541,7 +541,7 @@ H5FD__direct_open(const char *name, unsigned flags, hid_t fapl_id, haddr_t maxad } else { file->fa.must_align = false; - if (-1 == HDftruncate(file->fd, (HDoff_t)0)) + if (-1 == HDftruncate(file->fd, 0)) HSYS_GOTO_ERROR(H5E_IO, H5E_SEEKERROR, NULL, "unable to truncate file") } } @@ -554,7 +554,7 @@ H5FD__direct_open(const char *name, unsigned flags, hid_t fapl_id, haddr_t maxad } else { if (o_flags & O_RDWR) { - if (HDlseek(file->fd, (HDoff_t)0, SEEK_SET) < 0) + if (HDlseek(file->fd, 0, SEEK_SET) < 0) HSYS_GOTO_ERROR(H5E_IO, H5E_SEEKERROR, NULL, "unable to seek to proper position") if (HDwrite(file->fd, buf1, sizeof(int)) < 0) file->fa.must_align = true; |