summaryrefslogtreecommitdiff
path: root/indra
diff options
context:
space:
mode:
authorandreykproductengine <andreykproductengine@lindenlab.com>2017-08-30 17:44:21 +0300
committerandreykproductengine <andreykproductengine@lindenlab.com>2017-08-30 17:44:21 +0300
commit9d9c04b0448e33b104f6e5b5cb1aea3df63bca9d (patch)
tree8a93dfa1deccdecc8318e4c8042613dc1249212b /indra
parentbcb3bea0a9fe610e8007e67b6ad26ae10f4cb431 (diff)
MAINT-7691 One more crashreported issue with unicode in windows
Diffstat (limited to 'indra')
-rw-r--r--indra/llcrashlogger/llcrashlock.cpp14
-rw-r--r--indra/llcrashlogger/llcrashlogger.cpp2
2 files changed, 13 insertions, 3 deletions
diff --git a/indra/llcrashlogger/llcrashlock.cpp b/indra/llcrashlogger/llcrashlock.cpp
index 7dde1fcd69..77abfbcf0f 100644
--- a/indra/llcrashlogger/llcrashlock.cpp
+++ b/indra/llcrashlogger/llcrashlock.cpp
@@ -188,12 +188,22 @@ LLSD LLCrashLock::getProcessList()
//static
bool LLCrashLock::fileExists(std::string filename)
{
- return boost::filesystem::exists(filename.c_str());
+#ifdef LL_WINDOWS // or BOOST_WINDOWS_API
+ boost::filesystem::path file_path(utf8str_to_utf16str(filename));
+#else
+ boost::filesystem::path file_path(filename);
+#endif
+ return boost::filesystem::exists(file_path);
}
void LLCrashLock::cleanupProcess(std::string proc_dir)
{
- boost::filesystem::remove_all(proc_dir);
+#ifdef LL_WINDOWS // or BOOST_WINDOWS_API
+ boost::filesystem::path dir_path(utf8str_to_utf16str(proc_dir));
+#else
+ boost::filesystem::path dir_path(proc_dir);
+#endif
+ boost::filesystem::remove_all(dir_path);
}
bool LLCrashLock::putProcessList(const LLSD& proc_sd)
diff --git a/indra/llcrashlogger/llcrashlogger.cpp b/indra/llcrashlogger/llcrashlogger.cpp
index d8365eed94..1d58dba9ab 100644
--- a/indra/llcrashlogger/llcrashlogger.cpp
+++ b/indra/llcrashlogger/llcrashlogger.cpp
@@ -462,7 +462,7 @@ bool LLCrashLogger::sendCrashLog(std::string dump_dir)
updateApplication("Sending reports...");
- std::ofstream out_file(report_file.c_str());
+ llofstream out_file(report_file.c_str());
LLSDSerialize::toPrettyXML(post_data, out_file);
out_file.flush();
out_file.close();