title: Unable to read data from the transport connection : An existing connection was forcibly closed by the remote host
body: <p>I have a server app and sometimes, when the client tries to connect, I get the following error: </p>
  
  <p><img src="https://i.stack.imgur.com/z8LND.jpg" alt="enter image description here"></p>
  
  <p><em>NOTE: the "couldn't get stream from client or login failed" is a text that's added by me in catch statement</em></p>
  
  <p>and the line at which it stops ( sThread : line 96 ) is : </p>
  
  <pre><code>tcpClient = (TcpClient)client;
  clientStream = tcpClient.GetStream();
  sr = new StreamReader(clientStream);
  sw = new StreamWriter(clientStream);
  
  // line 96:                 
  a = sr.ReadLine();
  </code></pre>
  
  <p>What may be causing this problem? Note that it doesn't happen all the time</p>