Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix crash when using WebSockets with URLSession.shared #5128

Merged
merged 1 commit into from
Nov 2, 2024

Conversation

jrflat
Copy link
Contributor

@jrflat jrflat commented Nov 1, 2024

The previous code expected all URLSessionWebSocketTask to have a delegate, so using a WebSocket task from URLSession.shared caused a fatalError. This PR updates that expectation so that having a delegate is not enforced.

Resolves #4730

@jrflat
Copy link
Contributor Author

jrflat commented Nov 1, 2024

@swift-ci please test

@jrflat jrflat requested a review from parkera November 1, 2024 19:36
@jrflat jrflat merged commit 8c0a11e into swiftlang:main Nov 2, 2024
2 checks passed
jrflat added a commit to jrflat/swift-corelibs-foundation that referenced this pull request Nov 3, 2024
jrflat added a commit to jrflat/swift-corelibs-foundation that referenced this pull request Nov 3, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

fatalError when trying to send a message using URLSessionWebSocketTask
2 participants