On Sep 2, 2012, at 7:31 AM, Gerriet M. Denkmann <gerr...@mdenkmann.de> wrote:
> On 2 Sep 2012, at 20:46, Matt Patenaude <m...@mattpatenaude.com> wrote:
> 
>> Are you using it in the asynchronous callback style, or the synchronous 
>> GetFlags function?
> 
> I am using:
> SCNetworkReachabilitySetCallback()
> SCNetworkReachabilityScheduleWithRunLoop()
> 
> Typical case:
> 2012-09-02 20:59:33.540 +0700 DidWakeNotification
> 2012-09-02 20:59:33.611 Error getaddrinfo(time.euro.apple.com, ntp) -> 
> nodename nor servname provided, or not known
> 2012-09-02 20:59:37.354  lost       internet connection 
> 2012-09-02 20:59:37.375  new        internet connection 
> 2012-09-02 20:59:37.391 try again - now everything is ok
> 
> Seems like it just takes some time after wake (DarkWake or normal wake) for 
> things to get sorted out.

One option would be to try the network during the DidWake notification, and if 
that fails then try again when the Reachability notification arrives. That 
should be more reliable and efficient than sleep/retry.


-- 
Greg Parker     gpar...@apple.com     Runtime Wrangler



_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
https://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Reply via email to