You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Once a UDP socket is connected in libuv, you have to call send with a null address or else you get UV_EISCONN and nothing is sent. There seems to be no way to do this through the uvw API, since the addr parameter is passed by reference. In udp.cc the wrappers are like:
Once a UDP socket is connected in libuv, you have to call send with a null address or else you get
UV_EISCONN
and nothing is sent. There seems to be no way to do this through the uvw API, since theaddr
parameter is passed by reference. In udp.cc the wrappers are like:Empirically it works to call it like
But this is undefined behavior in C++, and the compiler (at least Clang++-10) warns accordingly.
I think the right answer is to have versions of
UDPHandle::send
that don't take an address parameter.References:
http://docs.libuv.org/en/v1.x/udp.html in the uv_udp_send section
The text was updated successfully, but these errors were encountered: