mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-07-22 23:24:59 +00:00
PR6880: Don't dereference CallsExternalNode if it's NULL.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@101897 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -158,9 +158,11 @@ private:
|
|||||||
// destroy - Release memory for the call graph
|
// destroy - Release memory for the call graph
|
||||||
virtual void destroy() {
|
virtual void destroy() {
|
||||||
/// CallsExternalNode is not in the function map, delete it explicitly.
|
/// CallsExternalNode is not in the function map, delete it explicitly.
|
||||||
|
if (CallsExternalNode) {
|
||||||
CallsExternalNode->allReferencesDropped();
|
CallsExternalNode->allReferencesDropped();
|
||||||
delete CallsExternalNode;
|
delete CallsExternalNode;
|
||||||
CallsExternalNode = 0;
|
CallsExternalNode = 0;
|
||||||
|
}
|
||||||
CallGraph::destroy();
|
CallGraph::destroy();
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
Reference in New Issue
Block a user