new fields in BTF encoder state (used to support save and later addition of function) of ELF function representation need to be initialized. No need to set parameter names to NULL as got_parameter_names guards their use. A follow-on patch intended to be applied after the series [1]. [1] https://lore.kernel.org/bpf/1675790102-23037-1-git-send-email-alan.maguire@xxxxxxxxxx/ Suggested-by: Jiri Olsa <jolsa@xxxxxxxxxx> Signed-off-by: Alan Maguire <alan.maguire@xxxxxxxxxx> --- btf_encoder.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/btf_encoder.c b/btf_encoder.c index 35fb60a..ea5b47b 100644 --- a/btf_encoder.c +++ b/btf_encoder.c @@ -1020,6 +1020,8 @@ static int btf_encoder__collect_function(struct btf_encoder *encoder, GElf_Sym * } encoder->functions.entries[encoder->functions.cnt].generated = false; encoder->functions.entries[encoder->functions.cnt].function = NULL; + encoder->functions.entries[encoder->functions.cnt].state.got_parameter_names = false; + encoder->functions.entries[encoder->functions.cnt].state.type_id_off = 0; encoder->functions.cnt++; return 0; } -- 1.8.3.1