Index: tools/VisualBench/VisualBench.cpp |
diff --git a/tools/VisualBench/VisualBench.cpp b/tools/VisualBench/VisualBench.cpp |
index e97db8a308901b0223e948c9a9f29a03738aaaf7..d8713e743cc4b4fdfa29320697e51c7a5a332b3b 100644 |
--- a/tools/VisualBench/VisualBench.cpp |
+++ b/tools/VisualBench/VisualBench.cpp |
@@ -163,10 +163,7 @@ bool VisualBench::advanceRecordIfNecessary(SkCanvas* canvas) { |
return true; |
} |
- while ((fBenchmark = fBenchmarkStream->next()) && |
- (SkCommandLineFlags::ShouldSkip(FLAGS_match, fBenchmark->getUniqueName()) || |
- !fBenchmark->isSuitableFor(Benchmark::kGPU_Backend))) {} |
- |
+ fBenchmark.reset(fBenchmarkStream->next()); |
if (!fBenchmark) { |
return false; |
} |
@@ -238,7 +235,7 @@ void VisualBench::draw(SkCanvas* canvas) { |
fState = kPreWarmLoops_State; |
this->printStats(); |
fBenchmark->perCanvasPostDraw(canvas); |
- fBenchmark = NULL; |
+ fBenchmark.reset(NULL); |
fCurrentSample = 0; |
fFlushes = 1; |
fLoops = 1; |