diff options
author | Ishmanpreet Kaur Khera <khera.ishman@gmail.com> | 2015-10-20 21:45:12 +0530 |
---|---|---|
committer | Michal Privoznik <mprivozn@redhat.com> | 2015-10-21 15:03:35 +0200 |
commit | 32cee5b2f019afc735187137784657835d39f755 (patch) | |
tree | dc1a02fdd92150f6de81fbeb351f6d83ce874e94 /tests/virbitmaptest.c | |
parent | 1b4de77e852e37c157ad241f9b4ece9a271a43cc (diff) | |
download | libvirt-32cee5b2f019afc735187137784657835d39f755.tar.gz |
Avoid using !STREQ and !STRNEQ
We have macros for both positive and negative string matching.
Therefore there is no need to use !STREQ or !STRNEQ. At the same
time as we are dropping this, new syntax-check rule is
introduced to make sure we won't introduce it again.
Signed-off-by: Ishmanpreet Kaur Khera <khera.ishman@gmail.com>
Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
Diffstat (limited to 'tests/virbitmaptest.c')
-rw-r--r-- | tests/virbitmaptest.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/tests/virbitmaptest.c b/tests/virbitmaptest.c index a6e9a382f5..8e458d2597 100644 --- a/tests/virbitmaptest.c +++ b/tests/virbitmaptest.c @@ -355,7 +355,7 @@ test6(const void *v ATTRIBUTE_UNUSED) if (!str) goto error; - if (!STREQ(str, "")) + if (STRNEQ(str, "")) goto error; VIR_FREE(str); @@ -365,7 +365,7 @@ test6(const void *v ATTRIBUTE_UNUSED) if (!str) goto error; - if (!STREQ(str, "0")) + if (STRNEQ(str, "0")) goto error; VIR_FREE(str); @@ -376,7 +376,7 @@ test6(const void *v ATTRIBUTE_UNUSED) if (!str) goto error; - if (!STREQ(str, "0,4-5")) + if (STRNEQ(str, "0,4-5")) goto error; VIR_FREE(str); @@ -386,7 +386,7 @@ test6(const void *v ATTRIBUTE_UNUSED) if (!str) goto error; - if (!STREQ(str, "0,4-6")) + if (STRNEQ(str, "0,4-6")) goto error; VIR_FREE(str); @@ -399,7 +399,7 @@ test6(const void *v ATTRIBUTE_UNUSED) if (!str) goto error; - if (!STREQ(str, "0,4-6,13-16")) + if (STRNEQ(str, "0,4-6,13-16")) goto error; VIR_FREE(str); @@ -410,7 +410,7 @@ test6(const void *v ATTRIBUTE_UNUSED) if (!str) goto error; - if (!STREQ(str, "0,4-6,13-16,62-63")) + if (STRNEQ(str, "0,4-6,13-16,62-63")) goto error; |