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

Unified Diff: src/animator/SkAnimator.cpp

Issue 2343933002: Revert of SkFontData to use smart pointers. (Closed)
Patch Set: Created 4 years, 3 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/animator/SkAnimateMaker.cpp ('k') | src/core/SkFontDescriptor.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/animator/SkAnimator.cpp
diff --git a/src/animator/SkAnimator.cpp b/src/animator/SkAnimator.cpp
index c5aabbba4bdc62b7dd2ba81fed10ebf5e20e6262..ee75ab14affa8fc49f49df9e0ba6a200054338d6 100644
--- a/src/animator/SkAnimator.cpp
+++ b/src/animator/SkAnimator.cpp
@@ -82,10 +82,10 @@
// SkDebugf("animator decode %s\n", uri);
// SkStream* stream = SkStream::GetURIStream(fMaker->fPrefix.c_str(), uri);
- std::unique_ptr<SkStream> stream = SkStream::MakeFromFile(uri);
- if (stream) {
+ SkAutoTDelete<SkStream> stream(SkStream::NewFromFile(uri));
+ if (stream.get()) {
this->setURIBase(uri);
- return decodeStream(stream.get());
+ return decodeStream(stream);
} else {
return false;
}
« no previous file with comments | « src/animator/SkAnimateMaker.cpp ('k') | src/core/SkFontDescriptor.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698