Hi There,
We found an issue that caused NWUDPSession
stuck at NWUDPSessionStatePreparing
forever:
When the user switches from Wifi to cellular network, we will reconnect them using:
[self.session cancel];
NEPacketTunnelNetworkSettings* networkSettings = // new settings
[self updateTunnelNetworkSettings:networkSettings];
self.session = [self createUDPSessionToEndpoint:hostEndpoint fromEndpoint:nil];
[self waitForSessionToBeReadyUsingKVO];
// This line never executed while self.session.state stuck
// at NWUDPSessionStatePreparing
Any ideas on this issue?