diff options
-rw-r--r-- | tests/FontHostStreamTest.cpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/tests/FontHostStreamTest.cpp b/tests/FontHostStreamTest.cpp index 4fd88cc4da..30e469b410 100644 --- a/tests/FontHostStreamTest.cpp +++ b/tests/FontHostStreamTest.cpp @@ -72,7 +72,9 @@ static void test_fontHostStream(skiatest::Reporter* reporter) { paint.setColor(SK_ColorGRAY); paint.setTextSize(SkIntToScalar(30)); - paint.setTypeface(SkTypeface::CreateFromName("Georgia", SkTypeface::kNormal))->unref(); + SkTypeface* fTypeface = SkTypeface::CreateFromName("Georgia", + SkTypeface::kNormal); + SkSafeUnref(paint.setTypeface(fTypeface)); SkIRect origRect = SkIRect::MakeWH(64, 64); SkBitmap origBitmap; |