From 787bb480f6b615a4a4c7b65955452575a51b1587 Mon Sep 17 00:00:00 2001 From: joshualitt Date: Fri, 2 Jan 2015 10:54:26 -0800 Subject: Fix for chrome fuzzer TBR= BUG=skia: Review URL: https://codereview.chromium.org/801493003 --- src/gpu/GrBitmapTextContext.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'src/gpu/GrBitmapTextContext.cpp') diff --git a/src/gpu/GrBitmapTextContext.cpp b/src/gpu/GrBitmapTextContext.cpp index fdf96002bd..2df3a710d2 100755 --- a/src/gpu/GrBitmapTextContext.cpp +++ b/src/gpu/GrBitmapTextContext.cpp @@ -157,7 +157,8 @@ void GrBitmapTextContext::onDrawText(const GrPaint& paint, const SkPaint& skPain // if we have RGB, then we won't have any SkShaders so no need to use a localmatrix, but for // performance reasons we just invert here instead if (!viewMatrix.invert(&fLocalMatrix)) { - SkDebugf("Cannot invert viewmatrix\n"); + SkDebugf("Cannot invert viewmatrix\n"); + return; } while (text < stop) { @@ -205,7 +206,8 @@ void GrBitmapTextContext::onDrawPosText(const GrPaint& paint, const SkPaint& skP // if we have RGB, then we won't have any SkShaders so no need to use a localmatrix, but for // performance reasons we just invert here instead if (!viewMatrix.invert(&fLocalMatrix)) { - SkDebugf("Cannot invert viewmatrix\n"); + SkDebugf("Cannot invert viewmatrix\n"); + return; } int numGlyphs = fSkPaint.textToGlyphs(text, byteLength, NULL); -- cgit v1.2.3