diff options
author | Brad Payne (Vir Linden) <vir@lindenlab.com> | 2014-05-13 10:02:26 -0400 |
---|---|---|
committer | Brad Payne (Vir Linden) <vir@lindenlab.com> | 2014-05-13 10:02:26 -0400 |
commit | 7b9708a2e3aede6faef04bd546c497dc68264f58 (patch) | |
tree | c49b3779d7a1f2e94fa1d33396c882e3351a4797 /indra/llcrashlogger | |
parent | d0eb9658f2698b9c200991e84c1a60be48788e2c (diff) | |
parent | d0ef02c23a7a37c8c9bfe3a86bae88bb811fc9fe (diff) |
sunshine-external merge WIP
Diffstat (limited to 'indra/llcrashlogger')
-rw-r--r-- | indra/llcrashlogger/llcrashlock.cpp | 9 | ||||
-rwxr-xr-x | indra/llcrashlogger/llcrashlogger.cpp | 14 | ||||
-rwxr-xr-x | indra/llcrashlogger/llcrashlogger.h | 5 |
3 files changed, 13 insertions, 15 deletions
diff --git a/indra/llcrashlogger/llcrashlock.cpp b/indra/llcrashlogger/llcrashlock.cpp index c3d2f944fc..7fd7860707 100644 --- a/indra/llcrashlogger/llcrashlock.cpp +++ b/indra/llcrashlogger/llcrashlock.cpp @@ -31,7 +31,6 @@ #include "lldir.h" #include "llsd.h" #include "llsdserialize.h" -#include "llnametable.h" #include "llframetimer.h" #include <boost/filesystem.hpp> #include <string> @@ -40,15 +39,9 @@ #if LL_WINDOWS //For windows platform. -#include <windows.h> +#include <llwin32headers.h> #include <TlHelp32.h> -namespace { - inline DWORD getpid() { - return GetCurrentProcessId(); - } -} - bool LLCrashLock::isProcessAlive(U32 pid, const std::string& pname) { std::wstring wpname; diff --git a/indra/llcrashlogger/llcrashlogger.cpp b/indra/llcrashlogger/llcrashlogger.cpp index 29f192e81e..7a97c16ea7 100755 --- a/indra/llcrashlogger/llcrashlogger.cpp +++ b/indra/llcrashlogger/llcrashlogger.cpp @@ -61,7 +61,7 @@ public: protected: virtual void httpFailure() { - llwarns << dumpResponse() << llendl; + LL_WARNS() << dumpResponse() << LL_ENDL; gBreak = true; } @@ -214,8 +214,8 @@ void LLCrashLogger::gatherFiles() LLCurl::setCAFile(gDirUtilp->getCAFile()); } - llinfos << "Using log file from debug log " << mFileMap["SecondLifeLog"] << llendl; - llinfos << "Using settings file from debug log " << mFileMap["SettingsXml"] << llendl; + LL_INFOS() << "Using log file from debug log " << mFileMap["SecondLifeLog"] << LL_ENDL; + LL_INFOS() << "Using settings file from debug log " << mFileMap["SettingsXml"] << LL_ENDL; } else { @@ -494,7 +494,7 @@ bool LLCrashLogger::sendCrashLogs() } else { - llwarns << "Discarding corrupted entry from lock table." << llendl; + LL_WARNS() << "Discarding corrupted entry from lock table." << LL_ENDL; } } } @@ -512,7 +512,7 @@ void LLCrashLogger::updateApplication(const std::string& message) { gServicePump->pump(); gServicePump->callback(); - if (!message.empty()) llinfos << message << llendl; + if (!message.empty()) LL_INFOS() << message << LL_ENDL; } bool LLCrashLogger::init() @@ -566,13 +566,13 @@ bool LLCrashLogger::init() "1 = always send crash report, " "2 = never send crash report)"); - // llinfos << "Loading crash behavior setting" << llendl; + // LL_INFOS() << "Loading crash behavior setting" << LL_ENDL; // mCrashBehavior = loadCrashBehaviorSetting(); // If user doesn't want to send, bail out if (mCrashBehavior == CRASH_BEHAVIOR_NEVER_SEND) { - llinfos << "Crash behavior is never_send, quitting" << llendl; + LL_INFOS() << "Crash behavior is never_send, quitting" << LL_ENDL; return false; } diff --git a/indra/llcrashlogger/llcrashlogger.h b/indra/llcrashlogger/llcrashlogger.h index 78acc63b6a..a06bf1d6ac 100755 --- a/indra/llcrashlogger/llcrashlogger.h +++ b/indra/llcrashlogger/llcrashlogger.h @@ -35,6 +35,11 @@ #include "llcontrol.h" #include "llcrashlock.h" +// Crash reporter behavior +const S32 CRASH_BEHAVIOR_ASK = 0; +const S32 CRASH_BEHAVIOR_ALWAYS_SEND = 1; +const S32 CRASH_BEHAVIOR_NEVER_SEND = 2; + class LLCrashLogger : public LLApp { public: |