diff options
author | Albert Cheng <acheng@hdfgroup.org> | 1998-04-23 22:02:30 (GMT) |
---|---|---|
committer | Albert Cheng <acheng@hdfgroup.org> | 1998-04-23 22:02:30 (GMT) |
commit | ee65e2eb8c2292f5ad45452fe6521c8d944d96d9 (patch) | |
tree | ed41f4da5d8ef645b8061028b4924d36c57b6471 /src | |
parent | 6034a988cde841c002a9e467a6acd26cce895b8c (diff) | |
download | hdf5-ee65e2eb8c2292f5ad45452fe6521c8d944d96d9.zip hdf5-ee65e2eb8c2292f5ad45452fe6521c8d944d96d9.tar.gz hdf5-ee65e2eb8c2292f5ad45452fe6521c8d944d96d9.tar.bz2 |
[svn-r358] H5Fcreate did not accept EXCL creation flag correctly.
Fixed the typo where it should have checked exclusive
use of EXCL or TRUNC flags.
Diffstat (limited to 'src')
-rw-r--r-- | src/H5F.c | 4 |
1 files changed, 1 insertions, 3 deletions
@@ -1075,7 +1075,7 @@ H5Fcreate(const char *filename, uintn flags, hid_t create_id, if (flags & ~(H5F_ACC_EXCL|H5F_ACC_TRUNC|H5F_ACC_DEBUG)) { HGOTO_ERROR(H5E_ARGS, H5E_BADVALUE, FAIL, "invalid flags"); } - if ((flags & H5F_ACC_EXCL) && (flags & H5F_ACC_EXCL)) { + if ((flags & H5F_ACC_EXCL) && (flags & H5F_ACC_TRUNC)) { HGOTO_ERROR (H5E_ARGS, H5E_BADVALUE, FAIL, "mutually exclusive flags for file creation"); } @@ -1465,7 +1465,6 @@ H5F_block_read(H5F_t *f, const haddr_t *addr, hsize_t size, void *buf) FUNC_ENTER(H5F_block_read, FAIL); - if (0==size) return 0; assert (size < MAX_SIZET); /* convert the relative address to an absolute address */ @@ -1510,7 +1509,6 @@ H5F_block_write(H5F_t *f, const haddr_t *addr, hsize_t size, const void *buf) FUNC_ENTER(H5F_block_write, FAIL); - if (0==size) return 0; assert (size < MAX_SIZET); if (0 == (f->intent & H5F_ACC_RDWR)) { |