mirror of
https://github.com/OpenTTD/OpenTTD.git
synced 2026-07-24 12:06:41 +00:00
(svn r19741) [1.0] -Backport from trunk:
- Fix: Crash when using restart via rcon (r19722) - Fix: Leaking a file descriptor [FS#3785] (r19695) - Fix: Crash when the music/graphics metadata files were unreadable [FS#3774] (r19674)
This commit is contained in:
+3
-3
@@ -203,9 +203,9 @@ void GfxLoadSprites()
|
||||
GfxInitPalettes();
|
||||
}
|
||||
|
||||
bool GraphicsSet::FillSetDetails(IniFile *ini, const char *path)
|
||||
bool GraphicsSet::FillSetDetails(IniFile *ini, const char *path, const char *full_filename)
|
||||
{
|
||||
bool ret = this->BaseSet<GraphicsSet, MAX_GFT, DATA_DIR>::FillSetDetails(ini, path, false);
|
||||
bool ret = this->BaseSet<GraphicsSet, MAX_GFT, DATA_DIR>::FillSetDetails(ini, path, full_filename, false);
|
||||
if (ret) {
|
||||
IniGroup *metadata = ini->GetGroup("metadata");
|
||||
IniItem *item;
|
||||
@@ -213,7 +213,7 @@ bool GraphicsSet::FillSetDetails(IniFile *ini, const char *path)
|
||||
fetch_metadata("palette");
|
||||
this->palette = (*item->value == 'D' || *item->value == 'd') ? PAL_DOS : PAL_WINDOWS;
|
||||
}
|
||||
return true;
|
||||
return ret;
|
||||
}
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user