mirror of
https://github.com/JGRennison/OpenTTD-patches.git
synced 2024-11-16 00:12:51 +00:00
(svn r15259) -Fix: [NewGRF] small memory leak when scanning labels
This commit is contained in:
parent
adb5eac77e
commit
612975008e
@ -6169,6 +6169,9 @@ void LoadNewGRF(uint load_index, uint file_index)
|
|||||||
ClearTemporaryNewGRFData(_cur_grffile);
|
ClearTemporaryNewGRFData(_cur_grffile);
|
||||||
BuildCargoTranslationMap();
|
BuildCargoTranslationMap();
|
||||||
DEBUG(sprite, 2, "LoadNewGRF: Currently %i sprites are loaded", _cur_spriteid);
|
DEBUG(sprite, 2, "LoadNewGRF: Currently %i sprites are loaded", _cur_spriteid);
|
||||||
|
} else if (stage == GLS_INIT && HasBit(c->flags, GCF_INIT_ONLY)) {
|
||||||
|
/* We're not going to activate this, so free whatever data we allocated */
|
||||||
|
ClearTemporaryNewGRFData(_cur_grffile);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user