mirror of
https://github.com/jkcoxson/idevice.git
synced 2026-03-02 14:36:16 +01:00
Add IpAddr impl for RsdProvider
This commit is contained in:
@@ -157,3 +157,15 @@ impl IdeviceProvider for UsbmuxdProvider {
|
||||
})
|
||||
}
|
||||
}
|
||||
|
||||
#[cfg(feature = "tcp")]
|
||||
impl<'a> RsdProvider<'a> for std::net::IpAddr {
|
||||
async fn connect_to_service_port(
|
||||
&'a mut self,
|
||||
port: u16,
|
||||
) -> Result<Self::Stream, IdeviceError> {
|
||||
Ok(tokio::net::TcpStream::connect((*self, port)).await?)
|
||||
}
|
||||
|
||||
type Stream = tokio::net::TcpStream;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user