forked from M-Labs/artiq-zynq
cleanup
This commit is contained in:
parent
e76b84335e
commit
a4f5c7040b
|
@ -245,16 +245,15 @@ pub fn main() {
|
||||||
|
|
||||||
task::spawn(async move {
|
task::spawn(async move {
|
||||||
loop {
|
loop {
|
||||||
while let stream = TcpStream::accept(1381, 2048, 2048).await.unwrap() {
|
let stream = TcpStream::accept(1381, 2048, 2048).await.unwrap();
|
||||||
let control = control.clone();
|
let control = control.clone();
|
||||||
task::spawn(async {
|
task::spawn(async {
|
||||||
let _ = handle_connection(&stream, control)
|
let _ = handle_connection(&stream, control)
|
||||||
.await
|
.await
|
||||||
.map_err(|e| println!("Connection: {}", e));
|
.map_err(|e| println!("Connection: {}", e));
|
||||||
let _ = stream.flush().await;
|
let _ = stream.flush().await;
|
||||||
let _ = stream.abort().await;
|
let _ = stream.abort().await;
|
||||||
});
|
});
|
||||||
}
|
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue