Index: src/gpu/GrContext.cpp |
diff --git a/src/gpu/GrContext.cpp b/src/gpu/GrContext.cpp |
index ef80b5b290218e4b50d90bf53eb52f9ba36848b3..a4679a923c75bac501b92302947c69c1123fede8 100755 |
--- a/src/gpu/GrContext.cpp |
+++ b/src/gpu/GrContext.cpp |
@@ -1582,12 +1582,12 @@ void GrContext::setResourceCacheLimits(int maxTextures, size_t maxTextureBytes) |
fResourceCache->setLimits(maxTextures, maxTextureBytes); |
} |
-bool GrContext::addResourceToCache(const GrUniqueKey& key, GrGpuResource* resource) { |
+void GrContext::addResourceToCache(const GrUniqueKey& key, GrGpuResource* resource) { |
ASSERT_OWNED_RESOURCE(resource); |
- if (!resource || resource->wasDestroyed()) { |
- return false; |
+ if (!resource) { |
+ return; |
} |
- return resource->resourcePriv().setUniqueKey(key); |
+ resource->resourcePriv().setUniqueKey(key); |
} |
bool GrContext::isResourceInCache(const GrUniqueKey& key) const { |