[SR-13918] NWListener can't cancel and relisten #56316
Labels
bug
A deviation from expected or documented behavior. Also: expected but undesirable behavior.
standard library
Area: Standard library umbrella
Environment
iOS13
Additional Detail from JIRA
md5: ead23e7ba24e3180f0aa4a0f99b52063
Issue Description:
I have an app on iOS. I am to listen only while the app is in the foreground, and re-listen when it come back from background. However I call my stop() function and if I call start() subsequently it fails. Also if the app is terminated (in debugger or task manager) I cannot launch the app again for ~5 seconds because the listen() will fail.
Links:
https://stackoverflow.com/questions/63178889/swift-nwlistener-listen-cancel-and-relisten-successfully/64999960#64999960
https://forums.swift.org/t/how-to-listen-cancel-and-re-listen-with-nwlistener/39354/2
The text was updated successfully, but these errors were encountered: