summaryrefslogtreecommitdiffstats
path: root/libs/hwui
diff options
context:
space:
mode:
authorRomain Guy <romainguy@google.com>2011-01-14 15:37:54 -0800
committerRomain Guy <romainguy@google.com>2011-01-14 15:37:54 -0800
commit1f1fcb70b6e43a6b4df0dbab75a34429d4744624 (patch)
tree6f85a37e4e390f9f0d521ac306c8be59b3734916 /libs/hwui
parent24c00216687ac87fe531dc4d4168ac0c0ca04ea6 (diff)
downloadframeworks_base-1f1fcb70b6e43a6b4df0dbab75a34429d4744624.zip
frameworks_base-1f1fcb70b6e43a6b4df0dbab75a34429d4744624.tar.gz
frameworks_base-1f1fcb70b6e43a6b4df0dbab75a34429d4744624.tar.bz2
Don't delete objects twice...
Change-Id: Ibc67aed098c9300cf45eb46abda1938c418808c3
Diffstat (limited to 'libs/hwui')
-rw-r--r--libs/hwui/DisplayListRenderer.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/libs/hwui/DisplayListRenderer.h b/libs/hwui/DisplayListRenderer.h
index 112e455..f183473 100644
--- a/libs/hwui/DisplayListRenderer.h
+++ b/libs/hwui/DisplayListRenderer.h
@@ -413,10 +413,10 @@ private:
SkiaShader* shaderCopy = mShaderMap.valueFor(shader);
// TODO: We also need to handle generation ID changes in compose shaders
- if (!shaderCopy || shaderCopy->getGenerationId() != shader->getGenerationId()) {
+ if (shaderCopy == NULL || shaderCopy->getGenerationId() != shader->getGenerationId()) {
shaderCopy = shader->copy();
mShaderMap.add(shader, shaderCopy);
- mShaders.add(shader);
+ mShaders.add(shaderCopy);
}
addInt((int) shaderCopy);