From 8d7a6e023869a733d58c65dcbbb8b29f94a6f12b Mon Sep 17 00:00:00 2001 From: Tal Aloni Date: Mon, 3 Jun 2024 19:51:32 +0300 Subject: [PATCH] Client: Removed unneeded connectivity check before invoking EndReceive --- SMBLibrary/Client/SMB1Client.cs | 6 ------ SMBLibrary/Client/SMB2Client.cs | 6 ------ 2 files changed, 12 deletions(-) diff --git a/SMBLibrary/Client/SMB1Client.cs b/SMBLibrary/Client/SMB1Client.cs index 63ebcc7..ab6e9b7 100644 --- a/SMBLibrary/Client/SMB1Client.cs +++ b/SMBLibrary/Client/SMB1Client.cs @@ -429,12 +429,6 @@ namespace SMBLibrary.Client lock (state.ReceiveBuffer) { - if (!clientSocket.Connected) - { - state.ReceiveBuffer.Dispose(); - return; - } - int numberOfBytesReceived = 0; try { diff --git a/SMBLibrary/Client/SMB2Client.cs b/SMBLibrary/Client/SMB2Client.cs index d90cc0c..c3531e9 100644 --- a/SMBLibrary/Client/SMB2Client.cs +++ b/SMBLibrary/Client/SMB2Client.cs @@ -362,12 +362,6 @@ namespace SMBLibrary.Client lock (state.ReceiveBuffer) { - if (!clientSocket.Connected) - { - state.ReceiveBuffer.Dispose(); - return; - } - int numberOfBytesReceived = 0; try {