mirror of
https://github.com/htrefil/rkvm.git
synced 2025-01-18 10:26:12 +01:00
Buffer client reads
This commit is contained in:
parent
60439f061c
commit
ffd82bfec5
1 changed files with 2 additions and 0 deletions
|
@ -9,6 +9,7 @@ use std::path::{Path, PathBuf};
|
|||
use std::process;
|
||||
use structopt::StructOpt;
|
||||
use tokio::fs;
|
||||
use tokio::io::BufReader;
|
||||
use tokio::net::TcpStream;
|
||||
use tokio_native_tls::native_tls::{Certificate, TlsConnector};
|
||||
|
||||
|
@ -27,6 +28,7 @@ async fn run(server: &str, port: u16, certificate_path: &Path) -> Result<Infalli
|
|||
.into();
|
||||
|
||||
let stream = TcpStream::connect((server, port)).await?;
|
||||
let stream = BufReader::new(stream);
|
||||
let mut stream = connector
|
||||
.connect(server, stream)
|
||||
.await
|
||||
|
|
Loading…
Reference in a new issue