Fix leak in PictureNestingBench

R=mtklein@google.com
TBR=mtklein@google.com

Author: fmalita@chromium.org

Review URL: https://codereview.chromium.org/569313004
This commit is contained in:
fmalita 2014-09-15 18:20:10 -07:00 committed by Commit bot
parent 44162675ca
commit df886ea06f

View File

@ -23,8 +23,8 @@ public:
fPaint.setColor(SK_ColorRED);
fPaint.setAntiAlias(true);
fPaint.setStyle(SkPaint::kStroke_Style);
fName.printf("picture_nesting_%s_%d", name,
this->sierpinsky(SkCreateNullCanvas(), 0, fPaint));
SkAutoTUnref<SkCanvas> nullCanvas(SkCreateNullCanvas());
fName.printf("picture_nesting_%s_%d", name, this->sierpinsky(nullCanvas, 0, fPaint));
}
protected: