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

Unified Diff: bench/nanobench.cpp

Issue 2339273002: SkFontData to use smart pointers. (Closed)
Patch Set: Add trivial bodies to the trivial implementations. 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 | « no previous file | dm/DMSrcSink.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: bench/nanobench.cpp
diff --git a/bench/nanobench.cpp b/bench/nanobench.cpp
index 5db5137ffd6f1f288da6e607bf3919586a38aa10..433cfa89d9cdde2998fa3b4923ee1c2baf555631 100644
--- a/bench/nanobench.cpp
+++ b/bench/nanobench.cpp
@@ -645,8 +645,8 @@ public:
return nullptr;
}
- SkAutoTDelete<SkStream> stream(SkStream::NewFromFile(path));
- if (stream.get() == nullptr) {
+ std::unique_ptr<SkStream> stream = SkStream::MakeFromFile(path);
+ if (!stream) {
SkDebugf("Could not read %s.\n", path);
return nullptr;
}
« no previous file with comments | « no previous file | dm/DMSrcSink.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698