dotnet/runtime

Inconsistent behavior of Socket.SendToAsync(SocketAsyncEventArgs)

Open

#34.474 aperta il 2 apr 2020

Vedi su GitHub
 (3 commenti) (0 reazioni) (0 assegnatari)C# (5445 fork)batch import
area-System.Net.Socketsdocumentationhelp wantedtenet-compatibility

Metriche repository

Star
 (17.886 star)
Metriche merge PR
 (Merge medio 12g 11h) (661 PR mergiate in 30 g)

Descrizione

Socket.SendToAsync(SocketAsyncEventArgs) method has inconsistent behavior on different platforms if used for UDP socket for sending datagram to loopback address. On Linux (Ubuntu 18.04.03 LTS x64) it returns synchronously and SocketAsyncEventArgs.SocketError is SocketError.ConnectionRefused. On Windows 10 it returns synchronously but SocketError is SocketError.Success.

Guida contributor