Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(142)

Unified Diff: src/core/SkBitmapScaler.cpp

Issue 110383005: detect if the scaledimagecache returns a purged bitmap (Closed) Base URL: https://skia.googlecode.com/svn/trunk
Patch Set: Created 7 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/core/SkBitmapProcState.cpp ('k') | src/core/SkScaledImageCache.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/core/SkBitmapScaler.cpp
diff --git a/src/core/SkBitmapScaler.cpp b/src/core/SkBitmapScaler.cpp
index c28d4779c7ae60b3bc3c375b16605be8efdd2049..67a9508ee98250e4a401f471a3e5a877f49415ec 100644
--- a/src/core/SkBitmapScaler.cpp
+++ b/src/core/SkBitmapScaler.cpp
@@ -301,6 +301,8 @@ bool SkBitmapScaler::Resize(SkBitmap* resultPtr,
convolveProcs, true);
*resultPtr = result;
+ resultPtr->lockPixels();
+ SkASSERT(NULL != resultPtr->getPixels());
return true;
}
« no previous file with comments | « src/core/SkBitmapProcState.cpp ('k') | src/core/SkScaledImageCache.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698