• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Reachability flag is inverse of actual state in Simulator
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Reachability flag is inverse of actual state in Simulator


  • Subject: Re: Reachability flag is inverse of actual state in Simulator
  • From: Jens Alfke <email@hidden>
  • Date: Mon, 04 Nov 2013 16:15:13 -0800


On Nov 4, 2013, at 3:46 PM, Rick Mann <email@hidden> wrote:

I’m using SCNetworkReachability. I get called back on network state changes (I’m unplugging and plugging the ethernet cable on the Thunderbolt dongle on my Retina MacBook Pro). But the “reachable” bit is the inverse of the actual reachability. That is, it’s 0 when the cable is plugged in, and 1 when it’s unplugged. The first launch is always true, regardless of the state of the physical connection. Changes to the physical connection after that result in the callback with inverse reachability flags.

Weird. It sounds like maybe your call is one step behind, i.e. after the cord is unplugged you’re getting the state for before it got unplugged?

FWIW, I haven’t seen such issues. Here’s my own reachability wrapper code. Maybe there’s something different about what you’re doing?
https://github.com/couchbase/couchbase-lite-ios/blob/master/Source/CBLReachability.m

—Jens
 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Macnetworkprog mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Next by Date: Re: Wi-Fi network can't see Bonjour services on wired network
  • Next by thread: Re: Wi-Fi network can't see Bonjour services on wired network
  • Index(es):
    • Date
    • Thread