If log_path is empty, we shouldn't setChatLogsDir to it.
In fact, this may have been the cause of something Nomade Zhao brought up.

Also, InstantMessageLogPathAnyAccount was accidentally being set as a PerAccount
This commit is contained in:
Lirusaito
2013-03-29 15:53:30 -04:00
parent b0459b08b6
commit b3c78b0ca5

View File

@@ -233,8 +233,11 @@ void LLPrefsIMImpl::apply()
else
{
const std::string log_path = childGetText("log_path_string");
gSavedPerAccountSettings.setString("InstantMessageLogPathAnyAccount", log_path);
gDirUtilp->setChatLogsDir(log_path);
if (!log_path.empty())
{
gSavedSettings.setString("InstantMessageLogPathAnyAccount", log_path);
gDirUtilp->setChatLogsDir(log_path);
}
}
}