From e2de92fa6c7a85dbbba11b5c85856e89ee3f7fb0 Mon Sep 17 00:00:00 2001 From: Muxi Yan Date: Tue, 31 Jan 2017 16:30:52 -0800 Subject: port #9505 to master --- src/objective-c/GRPCClient/private/GRPCConnectivityMonitor.m | 2 ++ 1 file changed, 2 insertions(+) (limited to 'src') diff --git a/src/objective-c/GRPCClient/private/GRPCConnectivityMonitor.m b/src/objective-c/GRPCClient/private/GRPCConnectivityMonitor.m index 40afca2d3d..0e2fa13f2c 100644 --- a/src/objective-c/GRPCClient/private/GRPCConnectivityMonitor.m +++ b/src/objective-c/GRPCClient/private/GRPCConnectivityMonitor.m @@ -159,11 +159,13 @@ static void PassFlagsToContextInfoBlock(SCNetworkReachabilityRef target, if (strongSelf) { if (lossHandler && !flags.reachable) { lossHandler(); +#if TARGET_OS_IPHONE } else if (wifiStatusChangeHandler && strongSelf->_previousReachabilityFlags && (flags.isWWAN ^ strongSelf->_previousReachabilityFlags.isWWAN)) { wifiStatusChangeHandler(); +#endif } strongSelf->_previousReachabilityFlags = flags; } -- cgit v1.2.3