From b9e48061e06ec0c181757c9e80cc4dc72d614f4f Mon Sep 17 00:00:00 2001 From: Nick Alcock Date: Sat, 18 Oct 2025 13:26:24 +0100 Subject: [PATCH] libctf: tests: fix clang 21 uninitialized variable warning The warning is spurious (the variable is unused in this situation), but clang cannot know that. libctf/ChangeLog: * testsuite/libctf-writable/symtypetab-nonlinker-writeout.c: Initialize dummy variable. --- .../testsuite/libctf-writable/symtypetab-nonlinker-writeout.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libctf/testsuite/libctf-writable/symtypetab-nonlinker-writeout.c b/libctf/testsuite/libctf-writable/symtypetab-nonlinker-writeout.c index 7a2b88d6dfa..db11c36cb95 100644 --- a/libctf/testsuite/libctf-writable/symtypetab-nonlinker-writeout.c +++ b/libctf/testsuite/libctf-writable/symtypetab-nonlinker-writeout.c @@ -25,7 +25,7 @@ try_maybe_reporting (int report) ctf_dict_t *fp; ctf_id_t func, func2, func3, base, base2, base3; ctf_encoding_t e = { CTF_INT_SIGNED, 0, sizeof (long) }; - ctf_id_t dummy; + ctf_id_t dummy = 0; ctf_funcinfo_t fi; ctf_next_t *i = NULL; ctf_id_t symtype; -- 2.47.3