Index: src/core/SkBitmapScaler.cpp |
diff --git a/src/core/SkBitmapScaler.cpp b/src/core/SkBitmapScaler.cpp |
index 962fdce3758c126b2b81d1bf67588d45bcd392b0..965955a2dcbf6ebb8779da496089902666a9ca13 100644 |
--- a/src/core/SkBitmapScaler.cpp |
+++ b/src/core/SkBitmapScaler.cpp |
@@ -245,11 +245,13 @@ bool SkBitmapScaler::Resize(SkBitmap* resultPtr, const SkPixmap& source, ResizeM |
return false; |
} |
- BGRAConvolve2D(sourceSubset, static_cast<int>(source.rowBytes()), |
- !source.isOpaque(), filter.xFilter(), filter.yFilter(), |
- static_cast<int>(result.rowBytes()), |
- static_cast<unsigned char*>(result.getPixels()), |
- convolveProcs, true); |
+ if (!BGRAConvolve2D(sourceSubset, static_cast<int>(source.rowBytes()), |
+ !source.isOpaque(), filter.xFilter(), filter.yFilter(), |
+ static_cast<int>(result.rowBytes()), |
+ static_cast<unsigned char*>(result.getPixels()), |
+ convolveProcs, true)) { |
+ return false; |
+ } |
*resultPtr = result; |
resultPtr->lockPixels(); |