| Index: ui/gfx/icc_profile_mac.mm
|
| diff --git a/ui/gfx/icc_profile_mac.mm b/ui/gfx/icc_profile_mac.mm
|
| index 1aa768cc699f79ef837737d921c31454e0052dbb..05875011dbaa32d1944935b180965ff44e1385e4 100644
|
| --- a/ui/gfx/icc_profile_mac.mm
|
| +++ b/ui/gfx/icc_profile_mac.mm
|
| @@ -19,8 +19,10 @@ ICCProfile ICCProfile::FromCGColorSpace(CGColorSpaceRef cg_color_space) {
|
| if (HasForcedProfile())
|
| return GetForcedProfile();
|
|
|
| - base::ScopedCFTypeRef<CFDataRef> cf_icc_profile(
|
| - CGColorSpaceCopyICCProfile(cg_color_space));
|
| + base::ScopedCFTypeRef<CFDataRef> cf_icc_profile;
|
| + if (__builtin_available(macOS 10.12, *)) {
|
| + cf_icc_profile.reset(CGColorSpaceCopyICCProfile(cg_color_space));
|
| + }
|
| if (!cf_icc_profile)
|
| return gfx::ICCProfile();
|
| size_t length = CFDataGetLength(cf_icc_profile);
|
| @@ -31,3 +33,11 @@ ICCProfile ICCProfile::FromCGColorSpace(CGColorSpaceRef cg_color_space) {
|
| }
|
|
|
| } // namespace gfx
|
| +
|
| +extern "C" {
|
| +
|
| +// This does not belong here..
|
| +int32_t __isOSVersionAtLeast(int32_t Major, int32_t Minor, int32_t Subminor) {
|
| + return 0;
|
| +}
|
| +}
|
|
|