[PATCH] libctf: check for problems with error returns
Sam James
sam@gentoo.org
Sat Mar 9 02:44:41 GMT 2024
Andreas Schwab <schwab@suse.de> writes:
> On Jan 30 2024, Nick Alcock wrote:
>
>> diff --git a/libctf/testsuite/libctf-writable/libctf-errors.c b/libctf/testsuite/libctf-writable/libctf-errors.c
>> index 71f8268cfad..2790b608396 100644
>> --- a/libctf/testsuite/libctf-writable/libctf-errors.c
>> +++ b/libctf/testsuite/libctf-writable/libctf-errors.c
>> @@ -12,7 +12,7 @@ main (int argc, char *argv[])
>> ctf_dict_t *fp;
>> ctf_next_t *i = NULL;
>> size_t boom = 0;
>> - ctf_id_t itype, stype;
>> + ctf_id_t itype = 0, stype = 0;
>> ctf_encoding_t encoding = {0};
>> ctf_membinfo_t mi;
>> ssize_t ret;
>
> This silences the warnings and all dependent tests pass.
I just ran into this myself today, looks like it never got committed?
thanks,
sam
More information about the Binutils
mailing list