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

If you're getting a null NSURLResponse #8

Open
lipidfish opened this issue Feb 22, 2016 · 1 comment
Open

If you're getting a null NSURLResponse #8

lipidfish opened this issue Feb 22, 2016 · 1 comment

Comments

@lipidfish
Copy link

This one had me hung up for a while. In [SonosDiscovery discoverControllers]the NSURLSession produced a null NSURLResponse, even though pasting the URL into a browser produced a valid response.

This is because in iOS 9, the default behavior is to not allow clear-text HTTP sessions. Since the URL starts with http://, (i.e. not https://), there will be no response sent back, and the NSError object contains a message alerting you to this.

To work around this, see this article

@kalms
Copy link

kalms commented Feb 26, 2016

Caught the same thing yesterday. Been migrating it all to Swift 2.0 (because I'm bored and seems like a good chance to get into Swift)

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

No branches or pull requests

2 participants