Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(679)

Unified Diff: Source/platform/fonts/mac/FontCacheMac.mm

Issue 139243002: StringImpl should not be referred from StringImplCF. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Removed AtomicStringCF.cpp Created 6 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: Source/platform/fonts/mac/FontCacheMac.mm
diff --git a/Source/platform/fonts/mac/FontCacheMac.mm b/Source/platform/fonts/mac/FontCacheMac.mm
index ef8862c10067b78ed1e70e426fdb06014db97790..1839bca0b8ed0e44ce717998eecfd26c8f11256f 100644
--- a/Source/platform/fonts/mac/FontCacheMac.mm
+++ b/Source/platform/fonts/mac/FontCacheMac.mm
@@ -197,7 +197,9 @@ FontPlatformData* FontCache::createFontPlatformData(const FontDescription& fontD
NSInteger weight = toAppKitFontWeight(fontDescription.weight());
float size = fontSize;
- NSFont *nsFont = [WebFontCache fontWithFamily:family traits:traits weight:weight size:size];
+ NSString *nsFontFamily = [[NSString alloc] initWithUTF8String:family.utf8().data()];
+ NSFont *nsFont = [WebFontCache fontWithFamily:nsFontFamily traits:traits weight:weight size:size];
+ [nsFontFamily release];
if (!nsFont)
return 0;

Powered by Google App Engine
This is Rietveld 408576698