Geometry extensions: remove unnecessary smart pointer deletion
============================================================== When the geometry object is destroyed, std::vector's destructor is called, which in turn calls the destructor of the smart pointers. If a weak_ptr corresponding to one of those shared_ptr is locked (elsewhere, if FC were multithread), the underlaying resource will not be freed until said locked weak_ptr goes out of scope. It will then.
This commit is contained in:
@@ -192,8 +192,7 @@ Geometry::Geometry()
|
||||
|
||||
Geometry::~Geometry()
|
||||
{
|
||||
for(std::vector<std::shared_ptr<GeometryExtension>>::iterator it = extensions.begin(); it != extensions.end(); it++)
|
||||
(*it).reset();
|
||||
|
||||
}
|
||||
|
||||
// Persistence implementer
|
||||
|
||||
Reference in New Issue
Block a user