When there are no caches, this variable would be uninitialized. Reported by clang-scan. Not sure if that can ever happen, but IMHO initializing doesn't do harm.
-- v2: kerberos: Avoid potentially uninitialized variable (clang-scan)
From: Fabian Maurer dark.shadow4@web.de
Signed-off-by: Fabian Maurer dark.shadow4@web.de --- dlls/kerberos/unixlib.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/dlls/kerberos/unixlib.c b/dlls/kerberos/unixlib.c index 45cf494aa70..8d9b59b58d4 100644 --- a/dlls/kerberos/unixlib.c +++ b/dlls/kerberos/unixlib.c @@ -305,7 +305,7 @@ static NTSTATUS copy_tickets_to_client( struct ticket_list *list, KERB_QUERY_TKT
static NTSTATUS kerberos_fill_ticket_list( struct ticket_list *list ) { - NTSTATUS status; + NTSTATUS status = STATUS_SUCCESS; krb5_error_code err; krb5_context ctx; krb5_cccol_cursor cursor = NULL;
On Thu Jul 6 18:32:44 2023 +0000, Hans Leidekker wrote:
The patch introduces a test failure.
Thanks, I just assumed this was unrelated... Turns out, the tests rely on the fact that the uninitialized variable is 0. I thought I was just fixing an unlikely potential issue, didn't expect this to be actually affecting tests. Pushed an update.