Skip to content

Commit

Permalink
tunnel_service: close existing CoreDeviceProxy service before reopen
Browse files Browse the repository at this point in the history
  • Loading branch information
doronz88 committed Oct 2, 2024
1 parent bef4d8a commit 4e3d971
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions pymobiledevice3/remote/tunnel_service.py
Original file line number Diff line number Diff line change
Expand Up @@ -928,6 +928,7 @@ def remote_identifier(self) -> str:

@asynccontextmanager
async def start_tcp_tunnel(self) -> AsyncGenerator['TunnelResult', None]:
self.service.close()
self._service = await self._lockdown.aio_start_lockdown_service(self.SERVICE_NAME)
tunnel = RemotePairingTcpTunnel(self._service.reader, self._service.writer)
handshake_response = await tunnel.request_tunnel_establish()
Expand Down

0 comments on commit 4e3d971

Please sign in to comment.