From 2eca3218ca1ac8fa582f86ab5f055474ad369d7d Mon Sep 17 00:00:00 2001 From: David Robillard Date: Sat, 10 Dec 2022 12:56:44 -0500 Subject: Fix "suspicious" string comparisons --- test/.clang-tidy | 1 - test/test_sratom.c | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) (limited to 'test') diff --git a/test/.clang-tidy b/test/.clang-tidy index e4b41e4..d335ce8 100644 --- a/test/.clang-tidy +++ b/test/.clang-tidy @@ -3,7 +3,6 @@ Checks: > -*-magic-numbers, - -bugprone-suspicious-string-compare, -cert-err33-c, -readability-identifier-length, InheritParentConfig: true diff --git a/test/test_sratom.c b/test/test_sratom.c index 246b5c5..3fa2db6 100644 --- a/test/test_sratom.c +++ b/test/test_sratom.c @@ -362,7 +362,7 @@ test(SerdEnv* env, bool top_level, bool pretty_numbers) LV2_ATOM_BODY(parsed)); printf("# Turtle => Atom\n\n%s", instr); - if (strcmp(outstr, instr)) { + if (!!strcmp(outstr, instr)) { return test_fail("Re-serialized string differs from original\n"); } free(instr); -- cgit v1.2.1