From: Bruce Richardson <bruce.richardson@intel.com>
To: dev@dpdk.org
Subject: [dpdk-dev] [PATCH] test: fix macro by adding in missing "do" in do-while
Date: Wed, 17 Dec 2014 17:06:53 +0000 [thread overview]
Message-ID: <1418836013-19030-1-git-send-email-bruce.richardson@intel.com> (raw)
One of the test assertion macros was missing the "do" part of the
do-while. This issue was picked up by clang reporting an empty while
loop body for the closing while of the do-while pair.
Signed-off-by: Bruce Richardson <bruce.richardson@intel.com>
---
app/test/test.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/app/test/test.h b/app/test/test.h
index 72e67b9..896f7db 100644
--- a/app/test/test.h
+++ b/app/test/test.h
@@ -44,7 +44,7 @@
} \
} while (0)
-#define TEST_ASSERT_EQUAL(a, b, msg, ...) { \
+#define TEST_ASSERT_EQUAL(a, b, msg, ...) do { \
if (!(a == b)) { \
printf("TestCase %s() line %d failed: " \
msg "\n", __func__, __LINE__, ##__VA_ARGS__); \
--
2.1.0
next reply other threads:[~2014-12-17 17:08 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-12-17 17:06 Bruce Richardson [this message]
2014-12-17 23:45 ` Thomas Monjalon
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1418836013-19030-1-git-send-email-bruce.richardson@intel.com \
--to=bruce.richardson@intel.com \
--cc=dev@dpdk.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).