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

Unified Diff: tests/ImageGeneratorTest.cpp

Issue 1231903006: Let's not leak this SkData. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 5 years, 5 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 | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/ImageGeneratorTest.cpp
diff --git a/tests/ImageGeneratorTest.cpp b/tests/ImageGeneratorTest.cpp
index a7151b93fbfe0f51ba247187f7ca8c8e94d1a5ee..1846f5762ebb65cf92839ddae5f9fe635885226b 100644
--- a/tests/ImageGeneratorTest.cpp
+++ b/tests/ImageGeneratorTest.cpp
@@ -19,7 +19,7 @@ static SkImageGenerator* my_factory(SkData*) {
static void test_imagegenerator_factory(skiatest::Reporter* reporter) {
// just need a non-empty data to test things
- SkData* data = SkData::NewWithCString("test_imagegenerator_factory");
+ SkAutoTUnref<SkData> data(SkData::NewWithCString("test_imagegenerator_factory"));
gMyFactoryWasCalled = false;
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698