summaryrefslogtreecommitdiffstats
path: root/libs/hwui/RenderNode.cpp
diff options
context:
space:
mode:
authorChris Craik <ccraik@google.com>2014-04-11 13:47:36 -0700
committerChris Craik <ccraik@google.com>2014-04-11 13:48:46 -0700
commit143912fef8eff58146705849a0ba441ab6163409 (patch)
treefcb26a8040ad41abe6d55457de06842e4dbc0702 /libs/hwui/RenderNode.cpp
parent494fb7b58a21a7a9a8eba3bacecffe115edcb8c6 (diff)
downloadframeworks_base-143912fef8eff58146705849a0ba441ab6163409.zip
frameworks_base-143912fef8eff58146705849a0ba441ab6163409.tar.gz
frameworks_base-143912fef8eff58146705849a0ba441ab6163409.tar.bz2
Remove use-after-free signal in RenderNode
bug:9321162 mDestroyed is no longer useful, as RenderNode is ref counted (not to mention having its lifecycle significantly redesigned). Change-Id: I429b9dd7740362c85d6416fbae567f0d47098e4e
Diffstat (limited to 'libs/hwui/RenderNode.cpp')
-rw-r--r--libs/hwui/RenderNode.cpp10
1 files changed, 1 insertions, 9 deletions
diff --git a/libs/hwui/RenderNode.cpp b/libs/hwui/RenderNode.cpp
index 823ae7b..bc0658f 100644
--- a/libs/hwui/RenderNode.cpp
+++ b/libs/hwui/RenderNode.cpp
@@ -50,17 +50,13 @@ void RenderNode::outputLogBuffer(int fd) {
}
RenderNode::RenderNode()
- : mDestroyed(false)
- , mNeedsPropertiesSync(false)
+ : mNeedsPropertiesSync(false)
, mNeedsDisplayListDataSync(false)
, mDisplayListData(0)
, mStagingDisplayListData(0) {
}
RenderNode::~RenderNode() {
- LOG_ALWAYS_FATAL_IF(mDestroyed, "Double destroyed DisplayList %p", this);
-
- mDestroyed = true;
delete mDisplayListData;
delete mStagingDisplayListData;
}
@@ -525,10 +521,6 @@ void RenderNode::issueOperationsOfProjectedChildren(OpenGLRenderer& renderer, T&
template <class T>
void RenderNode::issueOperations(OpenGLRenderer& renderer, T& handler) {
const int level = handler.level();
- if (CC_UNLIKELY(mDestroyed)) { // temporary debug logging
- ALOGW("Error: %s is drawing after destruction", mName.string());
- CRASH();
- }
if (mDisplayListData->isEmpty() || properties().getAlpha() <= 0) {
DISPLAY_LIST_LOGD("%*sEmpty display list (%p, %s)", level * 2, "", this, mName.string());
return;