diff --git a/components/settings/settings.cpp b/components/settings/settings.cpp index 13015e39c..3a3a3dddd 100644 --- a/components/settings/settings.cpp +++ b/components/settings/settings.cpp @@ -1,7 +1,8 @@ #include "settings.hpp" -#include #include +#include +#include #include #include @@ -25,7 +26,8 @@ void Manager::loadDefault (const std::string& file) void Manager::saveUser(const std::string& file) { - std::fstream fout(file.c_str(), std::ios::out); + namespace bfs = boost::filesystem; + bfs::ofstream fout(bfs::path(file)); Ogre::ConfigFile::SectionIterator seci = mFile.getSectionIterator(); diff --git a/components/translation/translation.cpp b/components/translation/translation.cpp index d0ea4b7fb..423c3971a 100644 --- a/components/translation/translation.cpp +++ b/components/translation/translation.cpp @@ -1,7 +1,8 @@ #include "translation.hpp" -#include -#include +#include + +#include namespace Translation { @@ -28,9 +29,8 @@ namespace Translation if (dataFileCollections.getCollection (extension).doesExist (fileName)) { - std::string path = dataFileCollections.getCollection (extension).getPath (fileName).string(); - - std::ifstream stream (path.c_str()); + boost::filesystem::ifstream stream ( + dataFileCollections.getCollection (extension).getPath (fileName)); if (!stream.is_open()) throw std::runtime_error ("failed to open translation file: " + fileName);