TcpConnector's 'close' method didn't call 'close' method on the underlying socket.
Accoring to the this and this 'close' method only closes outgoing stream. It leads to always running application (for example Example/main.dart), because application is waiting for asynchronous reading operation.
Also, I think it is better to flush the outgoing channel when socket is closing.
TcpConnector's 'close' method didn't call 'close' method on the underlying socket. Accoring to the this and this 'close' method only closes outgoing stream. It leads to always running application (for example Example/main.dart), because application is waiting for asynchronous reading operation.
Also, I think it is better to flush the outgoing channel when socket is closing.