forked from mirror/OpenTTD
(svn r10799) -Fix: only calling QuickFree and not the destructor on pool cleanups might cause memory leaks due to the way C++ works.
This commit is contained in:
@@ -37,6 +37,8 @@ Depot *GetDepotByTile(TileIndex tile)
|
||||
*/
|
||||
Depot::~Depot()
|
||||
{
|
||||
if (CleaningPool()) return;
|
||||
|
||||
/* Clear the depot from all order-lists */
|
||||
RemoveOrderFromAllVehicles(OT_GOTO_DEPOT, this->index);
|
||||
|
||||
|
Reference in New Issue
Block a user