Index: src/gpu/GrTextureParamsAdjuster.cpp |
diff --git a/src/gpu/GrTextureParamsAdjuster.cpp b/src/gpu/GrTextureParamsAdjuster.cpp |
index a91ba8a5e37e65199944393bc30767d60c919cbc..1d061375d9e70cc6469de644e72002f1d2c405f4 100644 |
--- a/src/gpu/GrTextureParamsAdjuster.cpp |
+++ b/src/gpu/GrTextureParamsAdjuster.cpp |
@@ -164,6 +164,11 @@ GrTexture* GrTextureAdjuster::refTextureSafeForParams(const GrTextureParams& par |
CopyParams copyParams; |
const SkIRect* contentArea = this->contentAreaOrNull(); |
+ if (!context) { |
+ // The texture was abandoned. |
+ return nullptr; |
+ } |
+ |
if (contentArea && GrTextureParams::kMipMap_FilterMode == params.filterMode()) { |
// If we generate a MIP chain for texture it will read pixel values from outside the content |
// area. |