Bug fixes for configuration handling.

Corrected retrieving installation path from wine registry on MacOS.
Updated doxygen comments.

Signed-off-by: Lukasz Gromanowski <lgromanowski@gmail.com>
This commit is contained in:
Lukasz Gromanowski 2012-02-23 23:21:17 +01:00
parent 3da6af6e38
commit d97854be00
2 changed files with 8 additions and 3 deletions

View File

@ -46,7 +46,7 @@ struct LinuxPath
boost::filesystem::path getUserPath() const; boost::filesystem::path getUserPath() const;
/** /**
* \brief Return path to the global (system) configuration directory. * \brief Return path to the global (system) directory where game files could be placed.
* *
* \return boost::filesystem::path * \return boost::filesystem::path
*/ */

View File

@ -105,11 +105,16 @@ boost::filesystem::path MacOsPath::getInstallPath() const
std::string line; std::string line;
std::string mwpath; std::string mwpath;
while (std::getline(file, line) && !line.empty()) while (std::getline(file, line))
{ {
if (line[0] == '[') // we found an entry if (line[0] == '[') // we found an entry
{ {
isRegEntry = (line.find("Softworks\\Morrowind]") != std::string::npos); if (isRegEntry)
{
break;
}
isRegEntry = (line.find("Softworks\\\\Morrowind]") != std::string::npos);
} }
else if (isRegEntry) else if (isRegEntry)
{ {