diff options
Diffstat (limited to 'Ivy/IvyTCPStreamV3.cs')
-rw-r--r-- | Ivy/IvyTCPStreamV3.cs | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/Ivy/IvyTCPStreamV3.cs b/Ivy/IvyTCPStreamV3.cs index aa76e93..00e8688 100644 --- a/Ivy/IvyTCPStreamV3.cs +++ b/Ivy/IvyTCPStreamV3.cs @@ -23,6 +23,7 @@ namespace IvyBus private StreamReader input;
private StreamWriter output;
private IvyProtocol receiver;
+ private Object outputLock = new Object();
internal IvyTCPStreamV3(Socket socket, IvyProtocol receiver) : base(socket)
{
@@ -67,8 +68,8 @@ namespace IvyBus private void SendMsg(MessageType msgType, int msgId, string msgData)
{
- // IOException Should be traited upstairs
- lock (this.output)
+ // IOException Should be traited upstairs
+ lock (this.outputLock)
{
this.output.Write((int)msgType);
this.output.Write(' ');
|