diff options
author | callum_linden <callum@lindenlab.com> | 2017-10-24 14:28:43 -0700 |
---|---|---|
committer | callum_linden <callum@lindenlab.com> | 2017-10-24 14:28:43 -0700 |
commit | d359dca06518d778c0f115afec8c759ca026de47 (patch) | |
tree | 97cd6df523508907b7bab1e443c714b18a243fc8 /indra | |
parent | 0ee774c39f3c689f998dae19d04af11981abd684 (diff) |
painfully add in the path to the second life log file that we also send - painful because of string <--> wstring issues
Diffstat (limited to 'indra')
-rw-r--r-- | indra/llcommon/llapp.cpp | 26 |
1 files changed, 5 insertions, 21 deletions
diff --git a/indra/llcommon/llapp.cpp b/indra/llcommon/llapp.cpp index ea4a0fb59c..6ea1700ea8 100644 --- a/indra/llcommon/llapp.cpp +++ b/indra/llcommon/llapp.cpp @@ -406,27 +406,11 @@ bool BugSplatExceptionCallback(unsigned int nCode, void* lpVal1, void* lpVal2) { case MDSCB_EXCEPTIONCODE: { - EXCEPTION_RECORD *p = (EXCEPTION_RECORD *)lpVal1; - DWORD code = p ? p->ExceptionCode : 0; - - // create some files in the %temp% directory and attach them - wchar_t cmdString[2 * MAX_PATH]; - wchar_t filePath[MAX_PATH]; - wchar_t tempPath[MAX_PATH]; - GetTempPathW(MAX_PATH, tempPath); - - wsprintf(filePath, L"%sfile1.txt", tempPath); - wsprintf(cmdString, L"echo Exception Code = 0x%08x > %s", code, filePath); - _wsystem(cmdString); - gBugSplatSender->sendAdditionalFile((const __wchar_t *)filePath); - - wsprintf(filePath, L"%sfile2.txt", tempPath); - wchar_t buf[_MAX_PATH]; - gBugSplatSender->getMinidumpPath((__wchar_t *)buf, _MAX_PATH); - - wsprintf(cmdString, L"echo Crash reporting is so clutch! minidump path = %s > %s", buf, filePath); - _wsystem(cmdString); - gBugSplatSender->sendAdditionalFile((const __wchar_t *)filePath); + // send the main viewer log file (Clearly a temporary hack since we don't have access to the gDir*** set of functions in newview + const std::string appdata = std::string(getenv("APPDATA")); + const std::string logfile = appdata + "\\SecondLife\\logs\\Secondlife.log"; + const std::wstring wide_logfile(logfile.begin(), logfile.end()); + gBugSplatSender->sendAdditionalFile((const __wchar_t *)wide_logfile.c_str()); } break; } |