diff options
author | Allen Byrne <byrn@hdfgroup.org> | 2020-09-30 14:27:10 (GMT) |
---|---|---|
committer | Allen Byrne <byrn@hdfgroup.org> | 2020-09-30 14:27:10 (GMT) |
commit | b2d661b508a7fc7a2592c13bc6bdc175551f075d (patch) | |
tree | 13baeb0d83a7c2a4c6299993c182b1227c2f6114 /examples/h5_drivers.c | |
parent | 29ab58b58dce556639ea3154e262895773a8a8df (diff) | |
download | hdf5-b2d661b508a7fc7a2592c13bc6bdc175551f075d.zip hdf5-b2d661b508a7fc7a2592c13bc6bdc175551f075d.tar.gz hdf5-b2d661b508a7fc7a2592c13bc6bdc175551f075d.tar.bz2 |
Clang-format of source files
Diffstat (limited to 'examples/h5_drivers.c')
-rw-r--r-- | examples/h5_drivers.c | 19 |
1 files changed, 8 insertions, 11 deletions
diff --git a/examples/h5_drivers.c b/examples/h5_drivers.c index 43c1fc7..486cf3b 100644 --- a/examples/h5_drivers.c +++ b/examples/h5_drivers.c @@ -22,13 +22,12 @@ #include "stdlib.h" /* global variables */ -int cleanup_g = -1; /* whether to clean. Init to not set. */ +int cleanup_g = -1; /* whether to clean. Init to not set. */ /* prototypes */ void cleanup(const char *); void split_file(void); - /* * Cleanup a file unless $HDF5_NOCLEANUP is set. */ @@ -36,12 +35,11 @@ void cleanup(const char *filename) { if (cleanup_g == -1) - cleanup_g = getenv("HDF5_NOCLEANUP") ? 0 : 1; + cleanup_g = getenv("HDF5_NOCLEANUP") ? 0 : 1; if (cleanup_g) - remove(filename); + remove(filename); } - /* * This shows how to use the split file driver. */ @@ -55,7 +53,7 @@ split_file(void) /* the metadata and rawdata files. */ fapl = H5Pcreate(H5P_FILE_ACCESS); H5Pset_fapl_split(fapl, "-m.h5", H5P_DEFAULT, "-r.h5", H5P_DEFAULT); - fid=H5Fcreate("Station1",H5F_ACC_TRUNC,H5P_DEFAULT,fapl); + fid = H5Fcreate("Station1", H5F_ACC_TRUNC, H5P_DEFAULT, fapl); /* using the file ... */ H5Fclose(fid); H5Pclose(fapl); @@ -68,7 +66,7 @@ split_file(void) /* the metadata and rawdata files. */ fapl = H5Pcreate(H5P_FILE_ACCESS); H5Pset_fapl_split(fapl, "-m.h5", H5P_DEFAULT, "/tmp/%s-r.h5", H5P_DEFAULT); - fid=H5Fcreate("PointA",H5F_ACC_TRUNC,H5P_DEFAULT,fapl); + fid = H5Fcreate("PointA", H5F_ACC_TRUNC, H5P_DEFAULT, fapl); /* using the file ... */ H5Fclose(fid); H5Pclose(fapl); @@ -81,7 +79,7 @@ split_file(void) /* the metadata and rawdata files. */ fapl = H5Pcreate(H5P_FILE_ACCESS); H5Pset_fapl_split(fapl, NULL, H5P_DEFAULT, NULL, H5P_DEFAULT); - fid=H5Fcreate("Measure",H5F_ACC_TRUNC,H5P_DEFAULT,fapl); + fid = H5Fcreate("Measure", H5F_ACC_TRUNC, H5P_DEFAULT, fapl); /* using the file ... */ H5Fclose(fid); H5Pclose(fapl); @@ -90,13 +88,12 @@ split_file(void) cleanup("Measure.raw"); } - /* Main Body */ int -main (void) +main(void) { split_file(); - return(0); + return (0); } |