diff options
Diffstat (limited to 'tools/skpbench/skpbench.cpp')
-rw-r--r-- | tools/skpbench/skpbench.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/tools/skpbench/skpbench.cpp b/tools/skpbench/skpbench.cpp index 569c204a72..20ba8b4ec4 100644 --- a/tools/skpbench/skpbench.cpp +++ b/tools/skpbench/skpbench.cpp @@ -335,8 +335,8 @@ int main(int argc, char** argv) { // Save a proof (if one was requested). if (!FLAGS_png.isEmpty()) { SkBitmap bmp; - bmp.setInfo(info); - if (!surface->getCanvas()->readPixels(&bmp, 0, 0)) { + bmp.allocPixels(info); + if (!surface->getCanvas()->readPixels(bmp, 0, 0)) { exitf(ExitErr::kUnavailable, "failed to read canvas pixels for png"); } const SkString &dirname = SkOSPath::Dirname(FLAGS_png[0]), |