Hi, On Mon, Jul 6, 2020 at 11:43 AM Gert Doering <g...@greenie.muc.de> wrote: > > Acked-by: Gert Doering <g...@greenie.muc.de> > > Thanks :-) - given that this is somewhat trivial, I have not actually > run a binary to look at the messages. I have counted arguments and done > a test build to see if new warnings show up (no). > > I *do* see an old warning... > > tun.c: In function 'windows_set_mtu': > tun.c:5523:21: warning: format '%u' expects argument of type 'unsigned int', > but argument 5 has type 'DWORD {aka long unsigned int}' [-Wformat=] > msg(M_WARN, "TUN: Setting %s mtu failed: %s [status=%u if_index=%d]",
It's ok if this is only for Windows code (I assume it is because of the name of the function) because x86 and ARM have the same endian-ness and are the only Windows platforms (that I know of). However, it would still be better to use "%lu" to avoid the warning and to future-proof it for any _new_ Windows platform that's different. (Although I admit Microsoft is unlikely to do that.) Best regards, Jon _______________________________________________ Openvpn-devel mailing list Openvpn-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/openvpn-devel