WriteMsgUDPAddrPort is kinda unusable otherwise. It didn't work when you did a net.Listen("udp", ":n") instead of "udp4" and then tried to send a UDP packet to an IPv4 address, as the operating system might've opened a unspecified address listener and it depends on the OS type & configuration on whether it supported IPv6 too. If it did, the v4 send wouldn't work.
Workaround is to use old APIs, or try the call twice both ways (at which point you're better off using the old APIs, as the retry's error garbage negated all the benefits of the new API's alloc-free properties).
As this is new-sh API, it's also low risk to fix. No behavior change for the path where it worked previously. It only makes things that would've failed now work.