aboutsummaryrefslogtreecommitdiffhomepage
path: root/gm/dftext.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'gm/dftext.cpp')
-rw-r--r--gm/dftext.cpp4
1 files changed, 1 insertions, 3 deletions
diff --git a/gm/dftext.cpp b/gm/dftext.cpp
index cccca3863d..545911c26c 100644
--- a/gm/dftext.cpp
+++ b/gm/dftext.cpp
@@ -201,9 +201,7 @@ protected:
SkAutoCanvasRestore acr(inputCanvas, true);
// since we prepended this matrix already, we blit using identity
inputCanvas->resetMatrix();
- SkImage* image = surface->newImageSnapshot();
- inputCanvas->drawImage(image, 0, 0, nullptr);
- image->unref();
+ inputCanvas->drawImage(surface->makeImageSnapshot().get(), 0, 0, nullptr);
}
#endif
}