]> git.ipfire.org Git - thirdparty/bind9.git/commit
Fix the clang 12 warnings with multi-line strings in string arrays
authorOndřej Surý <ondrej@sury.org>
Wed, 16 Sep 2020 08:33:01 +0000 (10:33 +0200)
committerOndřej Surý <ondrej@isc.org>
Thu, 1 Oct 2020 16:42:11 +0000 (18:42 +0200)
commit50db10b7ca89fa89e4dca9b62fbb2aa5aeb3d034
tree660adc46b2610a294c9afaaeba9a66c0023c2a4e
parent23ad0bcfa18a21a7825aee0708d0090d91281b51
Fix the clang 12 warnings with multi-line strings in string arrays

The clang 12 has a new warning that warns when using multi-line strings
in the string arrays, f.e.:

    { "aa",
      "b"
      "b",
      "cc" }

would generate warning like this:

    private_test.c:162:7: error: suspicious concatenation of string literals in an array initialization; did you mean to separate the elements with a comma? [-Werror,-Wstring-concatenation]
                                      "33333/RSASHA1" };
                                      ^
    private_test.c:161:7: note: place parentheses around the string literal to silence warning
                                      "Done removing signatures for key "
                                      ^
    private_test.c:197:7: error: suspicious concatenation of string literals in an array initialization; did you mean to separate the elements with a comma? [-Werror,-Wstring-concatenation]
                                      "NSEC chain",
                                      ^
    private_test.c:196:7: note: place parentheses around the string literal to silence warning
                                      "Removing NSEC3 chain 1 0 30 DEAF / creating "
                                      ^
    2 errors generated.

(cherry picked from commit 7b07f22969149ceb24ad9491696fabb66c333524)
lib/dns/tests/private_test.c