summaryrefslogtreecommitdiffstats
path: root/tools/src/h5perf/perf.c
diff options
context:
space:
mode:
authorDana Robinson <43805+derobins@users.noreply.github.com>2022-06-29 20:02:38 (GMT)
committerGitHub <noreply@github.com>2022-06-29 20:02:38 (GMT)
commit03ed7a3d790c2add2dccc15300005c1aec0f4f6f (patch)
treede1cc9a0c22eed50f696204e573a004c457aa3fb /tools/src/h5perf/perf.c
parentcb424b2c456c85bcb7c338cc96923dfa43b038be (diff)
downloadhdf5-03ed7a3d790c2add2dccc15300005c1aec0f4f6f.zip
hdf5-03ed7a3d790c2add2dccc15300005c1aec0f4f6f.tar.gz
hdf5-03ed7a3d790c2add2dccc15300005c1aec0f4f6f.tar.bz2
Fixes a few minor parallel warnings (#1832)
Diffstat (limited to 'tools/src/h5perf/perf.c')
-rw-r--r--tools/src/h5perf/perf.c13
1 files changed, 5 insertions, 8 deletions
diff --git a/tools/src/h5perf/perf.c b/tools/src/h5perf/perf.c
index 84be7e8..270af57 100644
--- a/tools/src/h5perf/perf.c
+++ b/tools/src/h5perf/perf.c
@@ -457,7 +457,7 @@ parse_args(int argc, char **argv)
}
}
- return (0);
+ return 0;
}
/*-------------------------------------------------------------------------
* Function: getenv_all
@@ -478,14 +478,9 @@ parse_args(int argc, char **argv)
* Programmer: Leon Arber
* 4/4/05
*
- * Modifications:
- * Use original getenv if MPI is not initialized. This happens
- * one uses the PHDF5 library to build a serial nature code.
- * Albert 2006/04/07
- *
*-------------------------------------------------------------------------
*/
-char *
+static char *
getenv_all(MPI_Comm comm, int root, const char *name)
{
int mpi_size, mpi_rank, mpi_initialized, mpi_finalized;
@@ -539,7 +534,9 @@ getenv_all(MPI_Comm comm, int root, const char *name)
#endif
}
else {
- /* use original getenv */
+ /* Use the original getenv if MPI is not initialized. This happens
+ * if you use the parallel HDF5 library to build a serial program.
+ */
if (env)
HDfree(env);
env = HDgetenv(name);