TcpClient; NetworkStream; ReadAsync; C#
问题 Please excuse my lack of knowledge regarding Tasks and Async. Using the TcpClient class I am creating a connection with an available server: void async RunClientAsync() { TcpClient client = new TcpClient(); try { await client.ConnectAsync(IPAddress.Parse("1.1.1.1"), 8889); Task.Start(() => ReadClientAsync(client)); } catch (Exception ex) { HandleException(ex); } } // ----- void async ReadClientAsync(TcpClient client) { byte[] bf = new byte[2048]; try { while(true) { int br = await client