From 4c75b6b48920837a78bff618ed09fa8915b735a8 Mon Sep 17 00:00:00 2001 From: hastigondaliya <118960681+hastigondaliya@users.noreply.github.com> Date: Thu, 26 Oct 2023 17:17:41 +0530 Subject: [PATCH] [posix] fix uninitialized pointer read (#9562) --- src/posix/platform/infra_if.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/posix/platform/infra_if.cpp b/src/posix/platform/infra_if.cpp index e86fdafed65..b787f4fec48 100644 --- a/src/posix/platform/infra_if.cpp +++ b/src/posix/platform/infra_if.cpp @@ -671,9 +671,9 @@ void InfraNetif::DiscoverNat64PrefixDone(union sigval sv) otError InfraNetif::DiscoverNat64Prefix(uint32_t aInfraIfIndex) { - otError error = OT_ERROR_NONE; - struct addrinfo *hints = nullptr; - struct gaicb *reqs[1]; + otError error = OT_ERROR_NONE; + struct addrinfo *hints = nullptr; + struct gaicb *reqs[1] = {nullptr}; struct sigevent sig; int status;