mirror of
https://github.com/baldurk/renderdoc.git
synced 2026-11-03 12:33:58 +00:00
Recursively delete all command buffer nodes to avoid leak
This commit is contained in:
2 files changed
+12
No files matched your search
@@ -206,7 +206,10 @@ WrappedVulkan::~WrappedVulkan()
|
||||
}
|
||||
|
||||
for(size_t i = 0; i < m_Partial.commandTree.size(); i++)
|
||||
{
|
||||
m_Partial.commandTree[i]->DeleteChildren();
|
||||
delete m_Partial.commandTree[i];
|
||||
}
|
||||
|
||||
delete m_Replay;
|
||||
}
|
||||
|
||||
@@ -662,6 +662,15 @@ private:
|
||||
rdcarray<CommandBufferNode *> childCmdNodes;
|
||||
CommandBufferNode *rootNode = NULL;
|
||||
bool renderPassActive = false;
|
||||
|
||||
void DeleteChildren()
|
||||
{
|
||||
for(CommandBufferNode *child : childCmdNodes)
|
||||
{
|
||||
child->DeleteChildren();
|
||||
delete child;
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
// CommandBufferExecuteInfo tracks the position of the execution of a secondary command buffer
|
||||
|
||||
Reference in new issue
Block a user