summaryrefslogtreecommitdiffstats
path: root/testpar/testphdf5.h
diff options
context:
space:
mode:
authorQuincey Koziol <koziol@hdfgroup.org>2003-12-10 16:52:29 (GMT)
committerQuincey Koziol <koziol@hdfgroup.org>2003-12-10 16:52:29 (GMT)
commit1ebb93f0f813e57a3ddc4450aa45494624c722c1 (patch)
tree0a570ece66e6b2fa0496c4ee7bfc7fc312c6105b /testpar/testphdf5.h
parent671ba90ce4540284c2b995ab8a365f4af904cdee (diff)
downloadhdf5-1ebb93f0f813e57a3ddc4450aa45494624c722c1.zip
hdf5-1ebb93f0f813e57a3ddc4450aa45494624c722c1.tar.gz
hdf5-1ebb93f0f813e57a3ddc4450aa45494624c722c1.tar.bz2
[svn-r7923] Purpose:
Bug fix Description: Clean up a couple more 1.6 compat bugs that showed up when the library was compiled with parallel support. Platforms tested: FreeBSD 4.9 (sleipnir) w/parallel & 1.6 compat config not tested with h5committest
Diffstat (limited to 'testpar/testphdf5.h')
-rw-r--r--testpar/testphdf5.h40
1 files changed, 40 insertions, 0 deletions
diff --git a/testpar/testphdf5.h b/testpar/testphdf5.h
index 3836ba6..711d189 100644
--- a/testpar/testphdf5.h
+++ b/testpar/testphdf5.h
@@ -33,6 +33,28 @@
#define MESG(x) \
if (verbose) printf("%s\n", x); \
+#ifdef H5_WANT_H5_V1_6_COMPAT
+#define VRFY(val, mesg) do { \
+ if (val) { \
+ if (*mesg != '\0') { \
+ MESG(mesg); \
+ } \
+ } else { \
+ printf("Proc %d: ", mpi_rank); \
+ printf("*** PHDF5 ERROR ***\n"); \
+ printf(" Assertion (%s) failed at line %4d in %s\n", \
+ mesg, (int)__LINE__, __FILE__); \
+ ++nerrors; \
+ fflush(stdout); \
+ if (!verbose) { \
+ printf("aborting MPI process\n"); \
+ MPI_Finalize(); \
+ exit(nerrors); \
+ } \
+ } \
+ H5Eclear(); \
+} while(0)
+#else /* H5_WANT_H5_V1_6_COMPAT */
#define VRFY(val, mesg) do { \
if (val) { \
if (*mesg != '\0') { \
@@ -53,12 +75,29 @@
} \
H5Eclear(H5E_DEFAULT); \
} while(0)
+#endif /* H5_WANT_H5_V1_6_COMPAT */
/*
* Checking for information purpose.
* If val is false, print mesg; else nothing.
* Either case, no error setting.
*/
+#ifdef H5_WANT_H5_V1_6_COMPAT
+#define INFO(val, mesg) do { \
+ if (val) { \
+ if (*mesg != '\0') { \
+ MESG(mesg); \
+ } \
+ } else { \
+ printf("Proc %d: ", mpi_rank); \
+ printf("*** PHDF5 REMARK (not an error) ***\n"); \
+ printf(" Condition (%s) failed at line %4d in %s\n", \
+ mesg, (int)__LINE__, __FILE__); \
+ fflush(stdout); \
+ } \
+ H5Eclear(); \
+} while(0)
+#else /* H5_WANT_H5_V1_6_COMPAT */
#define INFO(val, mesg) do { \
if (val) { \
if (*mesg != '\0') { \
@@ -73,6 +112,7 @@
} \
H5Eclear(H5E_DEFAULT); \
} while(0)
+#endif /* H5_WANT_H5_V1_6_COMPAT */
#define MPI_BANNER(mesg) do { \
printf("--------------------------------\n"); \