Timeout on port connect syn

This commit is contained in:
Jackson Coxson
2025-08-27 11:38:44 -06:00
parent 7baa8a73b5
commit 4fde7cf06b
5 changed files with 48 additions and 9 deletions

View File

@@ -7,6 +7,7 @@ use std::ptr::null_mut;
use futures::{Stream, StreamExt};
use idevice::core_device::DiagnostisServiceClient;
use idevice::{IdeviceError, ReadWrite, RsdService};
use log::debug;
use crate::core_device_proxy::AdapterHandle;
use crate::rsd::RsdHandshakeHandle;
@@ -45,12 +46,17 @@ pub unsafe extern "C" fn diagnostics_service_connect_rsd(
RUNTIME.block_on(async move {
let provider_ref = unsafe { &mut (*provider).0 };
let handshake_ref = unsafe { &mut (*handshake).0 };
debug!(
"Connecting to DiagnosticsService: provider {provider_ref:?}, handshake: {:?}",
handshake_ref.uuid
);
DiagnostisServiceClient::connect_rsd(provider_ref, handshake_ref).await
});
match res {
Ok(client) => {
debug!("Connected to DiagnosticsService");
let boxed = Box::new(DiagnosticsServiceHandle(client));
unsafe { *handle = Box::into_raw(boxed) };
null_mut()