Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
534 views
in Technique[技术] by (71.8m points)

networking - Why can't this iOS app access the network?

My (Unity) app complains that the my iPod does not have network connectivity while the device has full wi-fi connectivity (as evidenced by every other app, including Safari).

This isn't just one API point - all of them (Facebook, StoreKit, etc) claim that the network is not available.

This message is periodically sent to the console from my app:

<Error>: Could not successfully update network info during initialization.

which may (I think) be coming from CoreTelephony.

Any idea what is causing this? I get it in debug and adhoc builds. I do not have any Restrictions (from Settings) active on the device.

The device is iOS 6 and the base sdk is iOS 5.

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)

The "Could not successfully update network info during initialization." log is shown every time you initialize the CTTelephonyNetworkInfo in a device without SIM card, (iPod touch or iPad without 3G).

If it's very annoying, you can just initialize it once and do your network checks against that instance.


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...