mirror of
https://github.com/AquariaOSE/Aquaria.git
synced 2025-06-08 01:22:02 +00:00
Fix unnecessary error message with empty or non-existing songs.xml
This commit is contained in:
parent
17b8cd2079
commit
4a20874841
1 changed files with 7 additions and 1 deletions
|
@ -1252,8 +1252,14 @@ std::string Continuity::getInternalFormName()
|
||||||
|
|
||||||
void Continuity::loadIntoSongBank(const std::string &file)
|
void Continuity::loadIntoSongBank(const std::string &file)
|
||||||
{
|
{
|
||||||
|
if(!exists(file))
|
||||||
|
return;
|
||||||
|
|
||||||
XMLDocument doc;
|
XMLDocument doc;
|
||||||
if(readXML(file, doc) != XML_SUCCESS)
|
XMLError err = readXML(file, doc);
|
||||||
|
if(err == XML_ERROR_EMPTY_DOCUMENT)
|
||||||
|
return;
|
||||||
|
if(err != XML_SUCCESS)
|
||||||
{
|
{
|
||||||
errorLog("Failed to load song bank: Malformed XML");
|
errorLog("Failed to load song bank: Malformed XML");
|
||||||
return;
|
return;
|
||||||
|
|
Loading…
Add table
Reference in a new issue