| Index: src/gpu/effects/GrTextureStripAtlas.cpp
|
| diff --git a/src/gpu/effects/GrTextureStripAtlas.cpp b/src/gpu/effects/GrTextureStripAtlas.cpp
|
| index 51aaf53540a2aaf3ad866a56f9f2eb7d691f35bf..65096bf650329bae3bb9631caf70f1551e72dec5 100644
|
| --- a/src/gpu/effects/GrTextureStripAtlas.cpp
|
| +++ b/src/gpu/effects/GrTextureStripAtlas.cpp
|
| @@ -92,6 +92,9 @@ int GrTextureStripAtlas::lockRow(const SkBitmap& data) {
|
| VALIDATE;
|
| if (0 == fLockedRows) {
|
| this->lockTexture();
|
| + if (!fTexture) {
|
| + return -1;
|
| + }
|
| }
|
|
|
| int key = data.getGenerationID();
|
| @@ -204,6 +207,9 @@ void GrTextureStripAtlas::lockTexture() {
|
| fTexture = fDesc.fContext->findAndRefCachedTexture(key);
|
| if (NULL == fTexture) {
|
| fTexture = fDesc.fContext->createTexture(texDesc, true, NULL, 0);
|
| + if (!fTexture) {
|
| + return;
|
| + }
|
| fDesc.fContext->addResourceToCache(key, fTexture);
|
| // This is a new texture, so all of our cache info is now invalid
|
| this->initLRU();
|
|
|