diff options
author | Andrey Kleshchev <andreykproductengine@lindenlab.com> | 2020-08-01 01:19:10 +0300 |
---|---|---|
committer | Andrey Kleshchev <andreykproductengine@lindenlab.com> | 2020-08-01 01:26:04 +0300 |
commit | cc25193af9a64f36a75f401160f5757498f3e5fc (patch) | |
tree | 9082b76f92d8d983c4cadbcca7ac7dd0dfd15fcf /indra/newview/llconversationlog.cpp | |
parent | 03a33bf07541f4555c840e2323e9e68fadc72689 (diff) |
SL-12795 Fix existance of multiple chatlog files after name change
Diffstat (limited to 'indra/newview/llconversationlog.cpp')
-rw-r--r-- | indra/newview/llconversationlog.cpp | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/indra/newview/llconversationlog.cpp b/indra/newview/llconversationlog.cpp index 5539fa75dd..dcffaf5930 100644 --- a/indra/newview/llconversationlog.cpp +++ b/indra/newview/llconversationlog.cpp @@ -398,6 +398,23 @@ void LLConversationLog::deleteBackupLogs() } } +void LLConversationLog::verifyFilename(const LLUUID& session_id, const std::string &expected_filename) +{ + conversations_vec_t::iterator conv_it = mConversations.begin(); + for (; conv_it != mConversations.end(); ++conv_it) + { + if (conv_it->getSessionID() == session_id) + { + if (conv_it->getHistoryFileName() != expected_filename) + { + LLLogChat::renameLogFile(conv_it->getHistoryFileName(), expected_filename); + conv_it->updateHistoryFileName(expected_filename); + } + break; + } + } +} + bool LLConversationLog::moveLog(const std::string &originDirectory, const std::string &targetDirectory) { |