mirror of
https://github.com/OpenTTD/OpenTTD.git
synced 2025-06-23 13:40:35 +01:00
Codefix: Delete PersistentStorage when a town is deleted. (#12903)
This commit is contained in:
parent
e4c04e86c0
commit
0f0f3d74ca
@ -148,6 +148,9 @@ Town::~Town()
|
||||
}
|
||||
|
||||
/* Clear the persistent storage list. */
|
||||
for (auto &psa : this->psa_list) {
|
||||
delete psa;
|
||||
}
|
||||
this->psa_list.clear();
|
||||
|
||||
DeleteSubsidyWith(SourceType::Town, this->index);
|
||||
|
Loading…
Reference in New Issue
Block a user