From ac2b3c25d3c1fef9012ca225d9a0430a123a435a Mon Sep 17 00:00:00 2001 From: fcolin Date: Fri, 25 Nov 2011 13:15:50 +0000 Subject: correct bug on Close in mono Linux Env --- Ivy/IvyTCPStreamV3.cs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'Ivy/IvyTCPStreamV3.cs') diff --git a/Ivy/IvyTCPStreamV3.cs b/Ivy/IvyTCPStreamV3.cs index 6c23726..aa76e93 100644 --- a/Ivy/IvyTCPStreamV3.cs +++ b/Ivy/IvyTCPStreamV3.cs @@ -35,8 +35,10 @@ namespace IvyBus { this.output.Close(); this.input.Close(); - this.Socket.Shutdown(SocketShutdown.Both); + if ( this.Socket != null ) // Correct problem in Mono ( under linux ) + this.Socket.Shutdown(SocketShutdown.Both); base.Close(); + } /* the protocol magic numbers */ -- cgit v1.1