modified: src/client.rs
All checks were successful
gitea/Frida-android-native/pipeline/head This commit looks good
All checks were successful
gitea/Frida-android-native/pipeline/head This commit looks good
This commit is contained in:
parent
89a12509ed
commit
774fbaee5c
@ -47,10 +47,10 @@ pub async fn client_mode(client_config: ClientConfiguration, fd: i32, close_toke
|
||||
let cancel_dr = close_token.clone();
|
||||
let dev_read_task = tokio::spawn(async move {
|
||||
let mut buf = vec![0; 1400]; // mtu
|
||||
let listen = listen_dr.clone();
|
||||
loop {
|
||||
tokio::select! {
|
||||
_ = cancel_dr.cancelled() => {
|
||||
info!("Cancellation token has been thrown dev_read_task");
|
||||
return;
|
||||
}
|
||||
rr = dev_reader.read(&mut buf) => {
|
||||
@ -73,6 +73,7 @@ pub async fn client_mode(client_config: ClientConfiguration, fd: i32, close_toke
|
||||
loop {
|
||||
tokio::select! {
|
||||
_ = cancel_sr.cancelled() => {
|
||||
info!("Cancellation token has been thrown sock_read_task");
|
||||
return;
|
||||
}
|
||||
rr = sock_rec.recv(&mut buf) => {
|
||||
@ -135,8 +136,6 @@ pub async fn client_mode(client_config: ClientConfiguration, fd: i32, close_toke
|
||||
tokio::select! {
|
||||
_ = close_token.cancelled() => {
|
||||
info!("Cancellation token has been thrown");
|
||||
cancel_sr.send(());
|
||||
cancel_dr.send(());
|
||||
return;
|
||||
}
|
||||
rr = rx.recv() => {
|
||||
|
Loading…
x
Reference in New Issue
Block a user