This is somewhat of a silly-compiler-syndrome - especially since the 
last warning in this area was a true positive, now the addition of
the "if(ai)" clause - which has nothing whatsoever to do with the
return data or not - causes a warning (that we treat fatal) in mingw,
and only in the release builds...

But anyway, this is just a 32bit integer, not in the fast path, and
initializing things is generally a good idea :-)

Tested with the (upcoming) GHA mingw+release builds that reproduceably
fail without this change.

Your patch has been applied to the master branch.

commit e8dc7f35584df1f1cf920636cd5ac7232f0009a9
Author: Frank Lichtenheld
Date:   Mon Dec 8 18:03:13 2025 +0100

     socket: Initialize struct in_addr_t in getaddr()

     Signed-off-by: Frank Lichtenheld <[email protected]>
     Acked-by: Gert Doering <[email protected]>
     Gerrit URL: https://gerrit.openvpn.net/c/openvpn/+/1420
     Message-Id: <[email protected]>
     URL: 
https://www.mail-archive.com/[email protected]/msg34894.html
     Signed-off-by: Gert Doering <[email protected]>


--
kind regards,

Gert Doering



_______________________________________________
Openvpn-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/openvpn-devel

Reply via email to