Browse Source

Catch Socket.Shutdown exceptions

Tal Aloni 8 years ago
parent
commit
21137c30f2
1 changed files with 1 additions and 1 deletions
  1. 1 1
      ISCSI/Utilities/SocketUtils.cs

+ 1 - 1
ISCSI/Utilities/SocketUtils.cs

@@ -23,9 +23,9 @@ namespace Utilities
             {
                 if (socket.Connected)
                 {
-                    socket.Shutdown(SocketShutdown.Both);
                     try
                     {
+                        socket.Shutdown(SocketShutdown.Both);
                         socket.Disconnect(false);
                     }
                     catch (ObjectDisposedException)