Sets the socket address family to the one decided by the address passed in. (#148)

This commit is contained in:
Kieran Devlin 2022-11-07 06:02:16 +00:00 committed by GitHub
parent 7d07f65f7f
commit d56a50c49b
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 2 deletions

View file

@ -140,7 +140,7 @@ namespace SMBLibrary.Client
private bool ConnectSocket(IPAddress serverAddress, int port)
{
m_clientSocket = new Socket(AddressFamily.InterNetwork, SocketType.Stream, ProtocolType.Tcp);
m_clientSocket = new Socket(serverAddress.AddressFamily, SocketType.Stream, ProtocolType.Tcp);
try
{

View file

@ -145,7 +145,7 @@ namespace SMBLibrary.Client
private bool ConnectSocket(IPAddress serverAddress, int port)
{
m_clientSocket = new Socket(AddressFamily.InterNetwork, SocketType.Stream, ProtocolType.Tcp);
m_clientSocket = new Socket(serverAddress.AddressFamily, SocketType.Stream, ProtocolType.Tcp);
try
{