No need to enclose values in quotes when writing INI file. Print that file was saved to console and log.

This commit is contained in:
Bart Trzynadlowski 2017-03-27 03:10:36 +00:00
parent 35d9842dd8
commit 10befe4938

View file

@ -208,7 +208,7 @@ namespace Util
for (auto it = section.begin(); it != section.end(); ++it) for (auto it = section.begin(); it != section.end(); ++it)
{ {
if (it->IsLeaf()) //TODO: check if value exists? if (it->IsLeaf()) //TODO: check if value exists?
file << it->Key() << " = \"" << it->ValueAs<std::string>() << "\"" << std::endl; file << it->Key() << " = " << it->ValueAs<std::string>() << std::endl;
} }
file << std::endl << std::endl; file << std::endl << std::endl;
} }
@ -230,6 +230,8 @@ namespace Util
if (it->HasChildren()) if (it->HasChildren())
WriteSection(file, *it); WriteSection(file, *it);
} }
printf("Configuration successfully saved to '%s'.\n", filename.c_str());
InfoLog("Configuration successfully saved to '%s'.", filename.c_str());
} }
} }
} }