From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001 From: Jeremy Apthorp Date: Thu, 20 Sep 2018 17:49:20 -0700 Subject: mas-cfisobjc.patch Removes usage of the _CFIsObjC private API. diff --git a/base/mac/foundation_util.mm b/base/mac/foundation_util.mm index 38954c89527012ec72503240b0197bc24110d3ad..aebb6ec5815220f47a79dac59443e3b4bf3f0416 100644 --- a/base/mac/foundation_util.mm +++ b/base/mac/foundation_util.mm @@ -26,7 +26,6 @@ #if !defined(OS_IOS) CFTypeID SecACLGetTypeID(); CFTypeID SecTrustedApplicationGetTypeID(); -Boolean _CFIsObjC(CFTypeID typeID, CFTypeRef obj); #endif } // extern "C" @@ -325,8 +324,7 @@ void SetBaseBundleID(const char* new_base_bundle_id) { const_cast(reinterpret_cast(cf_val)); DCHECK(!cf_val || CTFontGetTypeID() == CFGetTypeID(cf_val) || - (_CFIsObjC(CTFontGetTypeID(), cf_val) && - [ns_val isKindOfClass:[NSFont class]])); + ([ns_val isKindOfClass:[NSFont class]])); return ns_val; } @@ -394,9 +392,6 @@ CTFontRef NSToCFCast(NSFont* ns_val) { return (CTFontRef)(cf_val); } - if (!_CFIsObjC(CTFontGetTypeID(), cf_val)) - return NULL; - id ns_val = reinterpret_cast(const_cast(cf_val)); if ([ns_val isKindOfClass:[NSFont class]]) { return (CTFontRef)(cf_val);