Corrected wrong deallocation when octree was destroyed after being never used.
This commit is contained in:
parent
01277711b6
commit
9fee0bfaaa
|
@ -214,9 +214,13 @@ namespace vcg
|
|||
};
|
||||
|
||||
public:
|
||||
Octree()
|
||||
{
|
||||
marks=0;
|
||||
}
|
||||
~Octree()
|
||||
{
|
||||
delete []marks;
|
||||
if(marks) delete []marks;
|
||||
int node_count = TemplatedOctree::NodeCount();
|
||||
for (int i=0; i<node_count; i++)
|
||||
delete TemplatedOctree::nodes[i];
|
||||
|
|
Loading…
Reference in New Issue