summaryrefslogtreecommitdiffstats
path: root/testpar
diff options
context:
space:
mode:
authorglennsong09 <43005495+glennsong09@users.noreply.github.com>2023-03-17 16:41:54 (GMT)
committerGitHub <noreply@github.com>2023-03-17 16:41:54 (GMT)
commitdfa4d550de4472055de0acbb265986f2d3414922 (patch)
tree11cd342e2fdaea9aa73c2083cb1889f7245d966f /testpar
parent2ca2a300ac73ec00c23151da9742ac221a6cd014 (diff)
downloadhdf5-dfa4d550de4472055de0acbb265986f2d3414922.zip
hdf5-dfa4d550de4472055de0acbb265986f2d3414922.tar.gz
hdf5-dfa4d550de4472055de0acbb265986f2d3414922.tar.bz2
Enclose MESG in do...while loop (#2576)
Enclose MSG macro in a do...while loop
Diffstat (limited to 'testpar')
-rw-r--r--testpar/testpar.h7
1 files changed, 5 insertions, 2 deletions
diff --git a/testpar/testpar.h b/testpar/testpar.h
index 6c380a9..58bcab4 100644
--- a/testpar/testpar.h
+++ b/testpar/testpar.h
@@ -30,8 +30,11 @@
* mesg is not an empty string.
*/
#define MESG(mesg) \
- if (VERBOSE_MED && *mesg != '\0') \
- HDprintf("%s\n", mesg)
+ do { \
+ if (VERBOSE_MED && *mesg != '\0') { \
+ HDprintf("%s\n", mesg); \
+ } \
+ } while (0)
/*
* VRFY: Verify if the condition val is true.