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

Unified Diff: src/fonts/SkFontMgr_indirect.cpp

Issue 1809733002: detach -> release (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: (C) Created 4 years, 9 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
« no previous file with comments | « src/fonts/SkFontMgr_fontconfig.cpp ('k') | src/gpu/GrClipMaskManager.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/fonts/SkFontMgr_indirect.cpp
diff --git a/src/fonts/SkFontMgr_indirect.cpp b/src/fonts/SkFontMgr_indirect.cpp
index 2470f8a69336adb904bfdb2b3a09afc2e9989dc2..fc0bd5c7ce8b16af764840da6cc5943937e7acbb 100644
--- a/src/fonts/SkFontMgr_indirect.cpp
+++ b/src/fonts/SkFontMgr_indirect.cpp
@@ -125,7 +125,7 @@ SkTypeface* SkFontMgr_Indirect::createTypefaceFromFontId(const SkFontIdentity& i
if (dataTypeface.get() != nullptr) {
SkAutoTDelete<SkStreamAsset> stream(dataTypeface->openStream(nullptr));
if (stream.get() != nullptr) {
- return fImpl->createFromStream(stream.detach(), dataTypefaceIndex);
+ return fImpl->createFromStream(stream.release(), dataTypefaceIndex);
}
}
@@ -135,7 +135,7 @@ SkTypeface* SkFontMgr_Indirect::createTypefaceFromFontId(const SkFontIdentity& i
return nullptr;
}
- SkAutoTUnref<SkTypeface> typeface(fImpl->createFromStream(stream.detach(), id.fTtcIndex));
+ SkAutoTUnref<SkTypeface> typeface(fImpl->createFromStream(stream.release(), id.fTtcIndex));
if (typeface.get() == nullptr) {
return nullptr;
}
@@ -146,7 +146,7 @@ SkTypeface* SkFontMgr_Indirect::createTypefaceFromFontId(const SkFontIdentity& i
newEntry.fTtcIndex = id.fTtcIndex;
newEntry.fTypeface = typeface.get(); // weak reference passed to new entry.
- return typeface.detach();
+ return typeface.release();
}
SkTypeface* SkFontMgr_Indirect::onMatchFamilyStyle(const char familyName[],
@@ -205,5 +205,5 @@ SkTypeface* SkFontMgr_Indirect::onLegacyCreateTypeface(const char familyName[],
face.reset(this->createTypefaceFromFontId(fontId));
}
- return face.detach();
+ return face.release();
}
« no previous file with comments | « src/fonts/SkFontMgr_fontconfig.cpp ('k') | src/gpu/GrClipMaskManager.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698