From b4a3fa3c76afaa49428589609ea0bf30ec7c49e5 Mon Sep 17 00:00:00 2001 From: Bhagirath Mehta Date: Wed, 29 Apr 2026 14:52:18 -0700 Subject: [PATCH] Suppress WWAN reachability deprecation warnings Add pragma to suppress SCNetworkReachability deprecation warnings in ODWReachability.m. These APIs (SCNetworkReachabilityCreateWithName, SCNetworkReachabilityCreateWithAddress) were deprecated in iOS 17.4 and trigger -Werror build failures in Xcode 26.4+. A full migration to NWPathMonitor is tracked separately; this unblocks the build. Fixes #1425 Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- third_party/Reachability/ODWReachability.m | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/third_party/Reachability/ODWReachability.m b/third_party/Reachability/ODWReachability.m index 7947f7df0..17da230b5 100644 --- a/third_party/Reachability/ODWReachability.m +++ b/third_party/Reachability/ODWReachability.m @@ -31,6 +31,12 @@ CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF #import #import +// The SCNetworkReachability APIs used throughout this file were deprecated +// in iOS 17.4. A full migration to NWPathMonitor is tracked separately; +// suppress the warnings for the entire file until then. +#pragma clang diagnostic push +#pragma clang diagnostic ignored "-Wdeprecated-declarations" + NSString *const kNetworkReachabilityChangedNotification = @"NetworkReachabilityChangedNotification"; @@ -432,7 +438,10 @@ -(BOOL)isReachableViaWWAN SCNetworkReachabilityFlags flags = 0; +#pragma clang diagnostic push +#pragma clang diagnostic ignored "-Wdeprecated-declarations" if(SCNetworkReachabilityGetFlags(self.reachabilityRef, &flags)) +#pragma clang diagnostic pop { // Check we're REACHABLE if(flags & kSCNetworkReachabilityFlagsReachable)