Skip to content

Commit

Permalink
Guard potential unavailability of NSStreamNetworkServiceTypeCallSigna…
Browse files Browse the repository at this point in the history
…ling.
  • Loading branch information
nlutsenko committed Aug 12, 2021
1 parent 5743b44 commit 6f61b54
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions SocketRocket/Internal/Utilities/SRURLUtilities.m
Original file line number Diff line number Diff line change
Expand Up @@ -68,9 +68,11 @@ extern BOOL SRURLRequiresSSL(NSURL *url)
case NSURLNetworkServiceTypeVoice:
networkServiceType = NSStreamNetworkServiceTypeVoice;
break;
case NSURLNetworkServiceTypeCallSignaling:
networkServiceType = NSStreamNetworkServiceTypeCallSignaling;
break;
case NSURLNetworkServiceTypeCallSignaling: {
if (@available(iOS 10.0, tvOS 10.0, macOS 10.12, *)) {
networkServiceType = NSStreamNetworkServiceTypeCallSignaling;
}
} break;
}
return networkServiceType;
}
Expand Down

0 comments on commit 6f61b54

Please sign in to comment.