Index: third_party/WebKit/Source/platform/fonts/FontCache.cpp |
diff --git a/third_party/WebKit/Source/platform/fonts/FontCache.cpp b/third_party/WebKit/Source/platform/fonts/FontCache.cpp |
index 07f072892a09fde557324b2fb16ffa7ba0cb82d7..3ecf3a100d22ffd5db68f5165909d6eb97180bc8 100644 |
--- a/third_party/WebKit/Source/platform/fonts/FontCache.cpp |
+++ b/third_party/WebKit/Source/platform/fonts/FontCache.cpp |
@@ -233,12 +233,9 @@ FontVerticalDataCache& fontVerticalDataCacheInstance() { |
return fontVerticalDataCache; |
} |
-void FontCache::setFontManager(const sk_sp<SkFontMgr>& fontManager) { |
+void FontCache::setFontManager(sk_sp<SkFontMgr> fontManager) { |
DCHECK(!s_staticFontManager); |
- s_staticFontManager = fontManager.get(); |
- // Explicitly AddRef since we're going to hold on to the object for the life |
- // of the program. |
- s_staticFontManager->ref(); |
+ s_staticFontManager = fontManager.release(); |
} |
PassRefPtr<OpenTypeVerticalData> FontCache::getVerticalData( |