summaryrefslogtreecommitdiffstats
path: root/testpar
diff options
context:
space:
mode:
authorAlbert Cheng <acheng@hdfgroup.org>2006-11-22 07:21:48 (GMT)
committerAlbert Cheng <acheng@hdfgroup.org>2006-11-22 07:21:48 (GMT)
commit2181e7cb3cb5be0b9b3c1c0ccd8cc7617e7b310a (patch)
treee9397ff700e42d1e3df216e7a591fe5f5747ab4f /testpar
parentd4600f0fbdb9c70d3bca3e35ef2d74ef39d5fb11 (diff)
downloadhdf5-2181e7cb3cb5be0b9b3c1c0ccd8cc7617e7b310a.zip
hdf5-2181e7cb3cb5be0b9b3c1c0ccd8cc7617e7b310a.tar.gz
hdf5-2181e7cb3cb5be0b9b3c1c0ccd8cc7617e7b310a.tar.bz2
[svn-r12969] Bug fix.
Description: h5_get_file_size() was coded to return 0 if failed but file size can be 0. Changed the failure return value to -1 which is allowed by the returned type of off_t which is a signed type. Also changed the checking code of the stat call to just == 0 since that is how it is defined. Test: Could test it in heping only. Both Sol and Copper failed to compiled due to error in the Direct IO VFD code.
Diffstat (limited to 'testpar')
-rw-r--r--testpar/t_mdset.c8
-rw-r--r--testpar/testphdf5.h1
2 files changed, 4 insertions, 5 deletions
diff --git a/testpar/t_mdset.c b/testpar/t_mdset.c
index 96f0f55..cf1d542 100644
--- a/testpar/t_mdset.c
+++ b/testpar/t_mdset.c
@@ -334,7 +334,7 @@ void big_dataset(void)
VRFY((ret >= 0), "H5Fclose succeeded");
/* Check that file of the correct size was created */
- file_size=h5_mpi_get_file_size(filename, MPI_COMM_WORLD, MPI_INFO_NULL);
+ file_size=h5_get_file_size(filename);
VRFY((file_size == 2147485696ULL), "File is correct size");
/*
@@ -363,7 +363,7 @@ void big_dataset(void)
VRFY((ret >= 0), "H5Fclose succeeded");
/* Check that file of the correct size was created */
- file_size=h5_mpi_get_file_size(filename, MPI_COMM_WORLD, MPI_INFO_NULL);
+ file_size=h5_get_file_size(filename);
VRFY((file_size == 4294969344ULL), "File is correct size");
/*
@@ -392,7 +392,7 @@ void big_dataset(void)
VRFY((ret >= 0), "H5Fclose succeeded");
/* Check that file of the correct size was created */
- file_size=h5_mpi_get_file_size(filename, MPI_COMM_WORLD, MPI_INFO_NULL);
+ file_size=h5_get_file_size(filename);
VRFY((file_size == 8589936640ULL), "File is correct size");
/* Close fapl */
@@ -1569,7 +1569,7 @@ void io_mode_confusion(void)
if ( verbose )
- HDfprintf(stdout, "%0d:%s: Done.\n", mpi_rank);
+ HDfprintf(stdout, "%0d:%s: Done.\n", mpi_rank, fcn_name);
return;
diff --git a/testpar/testphdf5.h b/testpar/testphdf5.h
index 49d7568..6040cb9 100644
--- a/testpar/testphdf5.h
+++ b/testpar/testphdf5.h
@@ -270,7 +270,6 @@ void compress_readAll(void);
/* commonly used prototypes */
hid_t create_faccess_plist(MPI_Comm comm, MPI_Info info, int l_facc_type, hbool_t use_gpfs);
-MPI_Offset h5_mpi_get_file_size(const char *filename, MPI_Comm comm, MPI_Info info);
int dataset_vrfy(hsize_t start[], hsize_t count[], hsize_t stride[],
hsize_t block[], DATATYPE *dataset, DATATYPE *original);