util: shut up clang-tidy about our use of strcat

These are pre-counted strings, we're fine.

Part-of: <https://gitlab.freedesktop.org/libinput/libinput/-/merge_requests/1175>
This commit is contained in:
Peter Hutterer 2025-04-03 13:16:06 +10:00 committed by Marge Bot
parent 0fc52abd79
commit 051ac26a20

View file

@ -192,10 +192,10 @@ strv_join(char **strv, const char *joiner)
str = zalloc(slen + 1); /* trailing \0 */
for (s = strv; *s; s++) {
strcat(str, *s);
strcat(str, *s); // NOLINT: security.insecureAPI.strcpy
--count;
if (count > 0)
strcat(str, joiner);
strcat(str, joiner); // NOLINT: security.insecureAPI.strcpy
}
return str;