From 32978176b1eb5de0455db85b3ef7d0eb6c85dda4 Mon Sep 17 00:00:00 2001 From: Vaxry Date: Mon, 5 Jan 2026 15:05:25 +0100 Subject: [PATCH] systemd/sdDaemon: initialize sockaddr_un --- src/helpers/SdDaemon.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/helpers/SdDaemon.cpp b/src/helpers/SdDaemon.cpp index d914eecf..c3008807 100644 --- a/src/helpers/SdDaemon.cpp +++ b/src/helpers/SdDaemon.cpp @@ -41,7 +41,7 @@ int NSystemd::sdNotify(int unsetEnvironment, const char* state) { // address length must be at most this; see man 7 unix size_t addrLen = strnlen(addr, 107); - struct sockaddr_un unixAddr; + struct sockaddr_un unixAddr = {0}; unixAddr.sun_family = AF_UNIX; strncpy(unixAddr.sun_path, addr, addrLen); if (unixAddr.sun_path[0] == '@')