From: Heiko Hund Date: Thu, 6 Jul 2023 17:19:22 +0000 (+0200) Subject: work around false positive warning with mingw 12 X-Git-Tag: v2.7_alpha1~437 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=d559affd313a8f995db15908887fbc8f16a24659;p=thirdparty%2Fopenvpn.git work around false positive warning with mingw 12 When cross compiling for Windows with Ubuntu 23.04 mingw complains about route.c:344:26: warning: ‘special.S_un.S_addr’ may be used uninitialized which is wrong technically. However the workaround isn't really intrusive and while there are other warnings caused by libtool, the cmake mingw build completes with -Werror now. Change-Id: I8a0f59707570722eab41af2db76980ced04e6d54 Signed-off-by: Heiko Hund Acked-by: Arne Schwabe Message-Id: <20230706171922.752429-1-heiko@ist.eigentlich.net> URL: https://www.mail-archive.com/openvpn-devel@lists.sourceforge.net/msg26831.html Signed-off-by: Gert Doering --- diff --git a/src/openvpn/route.c b/src/openvpn/route.c index 0d04a5a33..0b369da44 100644 --- a/src/openvpn/route.c +++ b/src/openvpn/route.c @@ -319,7 +319,7 @@ init_route(struct route_ipv4 *r, const in_addr_t default_netmask = IPV4_NETMASK_HOST; bool status; int ret; - struct in_addr special; + struct in_addr special = {0}; CLEAR(*r); r->option = ro;