Fix write issue in tcp_client_pool