summaryrefslogtreecommitdiff
path: root/indra/llcommon/llerror.cpp
diff options
context:
space:
mode:
authorNat Goodspeed <nat@lindenlab.com>2018-09-26 16:50:58 -0400
committerNat Goodspeed <nat@lindenlab.com>2018-09-26 16:50:58 -0400
commitfc8b4ec587d8a05579244940e30b81519a1ebf91 (patch)
treed8ab8cd0d3935f43a194946c4a65f2aad7f1b025 /indra/llcommon/llerror.cpp
parent1e8851c4dfc40fe7dc39b7b3cfae5af97f709290 (diff)
DRTVWR-447: Finish pulling in new viewer-release.
Diffstat (limited to 'indra/llcommon/llerror.cpp')
-rw-r--r--indra/llcommon/llerror.cpp27
1 files changed, 19 insertions, 8 deletions
diff --git a/indra/llcommon/llerror.cpp b/indra/llcommon/llerror.cpp
index 06c7aef8ab..6dfb4bf028 100644
--- a/indra/llcommon/llerror.cpp
+++ b/indra/llcommon/llerror.cpp
@@ -368,6 +368,7 @@ namespace
public:
std::ostringstream messageStream;
bool messageStreamInUse;
+ std::string mFatalMessage;
void addCallSite(LLError::CallSite&);
void invalidateCallSites();
@@ -666,11 +667,16 @@ namespace LLError
s->mCrashFunction = f;
}
- FatalFunction getFatalFunction()
- {
+ FatalFunction getFatalFunction()
+ {
SettingsConfigPtr s = Settings::getInstance()->getSettingsConfig();
- return s->mCrashFunction;
- }
+ return s->mCrashFunction;
+ }
+
+ std::string getFatalMessage()
+ {
+ return Globals::getInstance()->mFatalMessage;
+ }
void setTimeFunction(TimeFunction f)
{
@@ -1256,12 +1262,17 @@ namespace LLError
}
addEscapedMessage(message_stream, message);
+ std::string message_line(message_stream.str());
- writeToRecorders(site, message_stream.str());
-
- if (site.mLevel == LEVEL_ERROR && s->mCrashFunction)
+ writeToRecorders(site, message_line);
+
+ if (site.mLevel == LEVEL_ERROR)
{
- s->mCrashFunction(message_stream.str());
+ g->mFatalMessage = message_line;
+ if (s->mCrashFunction)
+ {
+ s->mCrashFunction(message_line);
+ }
}
}
}