summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrey Kleshchev <andreykproductengine@lindenlab.com>2025-02-26 15:58:18 +0200
committerAndrey Kleshchev <117672381+akleshchev@users.noreply.github.com>2025-02-26 21:50:46 +0200
commit454d5b48715772889db12d142486e75a3a4dfed3 (patch)
treea936780de50b4a6d97d83083b433f3326ddb5dd3
parent056dc00ebe07ba5994a51c7b4eb38d887d4b9355 (diff)
#3591 Reprot SEH directly to bugsplat
Rethrowing SEH via std::exception results ina callstack that ends at rethrow.
-rw-r--r--indra/llcommon/llapp.h2
-rw-r--r--indra/llcommon/llcoros.cpp6
-rw-r--r--indra/newview/llappviewerwin32.cpp4
-rw-r--r--indra/newview/llappviewerwin32.h2
4 files changed, 9 insertions, 5 deletions
diff --git a/indra/llcommon/llapp.h b/indra/llcommon/llapp.h
index 3d18864b80..57f5a112d9 100644
--- a/indra/llcommon/llapp.h
+++ b/indra/llcommon/llapp.h
@@ -282,7 +282,7 @@ public:
LLRunner& getRunner() { return mRunner; }
#ifdef LL_WINDOWS
- virtual void reportCrashToBugsplat(void* pExcepInfo /*EXCEPTION_POINTERS*/) { }
+ virtual bool reportCrashToBugsplat(void* pExcepInfo /*EXCEPTION_POINTERS*/) { return false; }
#endif
public:
diff --git a/indra/llcommon/llcoros.cpp b/indra/llcommon/llcoros.cpp
index 1539b48bd3..ab56a3d3b7 100644
--- a/indra/llcommon/llcoros.cpp
+++ b/indra/llcommon/llcoros.cpp
@@ -310,18 +310,20 @@ namespace
static const U32 STATUS_MSC_EXCEPTION = 0xE06D7363; // compiler specific
-U32 exception_filter(U32 code, struct _EXCEPTION_POINTERS *exception_infop)
+U32 exception_filter(U32 code, struct _EXCEPTION_POINTERS* exception_infop)
{
if (code == STATUS_MSC_EXCEPTION)
{
// C++ exception, go on
return EXCEPTION_CONTINUE_SEARCH;
}
- else
+ else if (!LLApp::instance()->reportCrashToBugsplat((void*)exception_infop))
{
// handle it
return EXCEPTION_EXECUTE_HANDLER;
}
+
+ return EXCEPTION_CONTINUE_SEARCH;
}
void sehandle(const LLCoros::callable_t& callable)
diff --git a/indra/newview/llappviewerwin32.cpp b/indra/newview/llappviewerwin32.cpp
index 023ec3410a..b4a2479520 100644
--- a/indra/newview/llappviewerwin32.cpp
+++ b/indra/newview/llappviewerwin32.cpp
@@ -804,14 +804,16 @@ bool LLAppViewerWin32::cleanup()
return result;
}
-void LLAppViewerWin32::reportCrashToBugsplat(void* pExcepInfo)
+bool LLAppViewerWin32::reportCrashToBugsplat(void* pExcepInfo)
{
#if defined(LL_BUGSPLAT)
if (sBugSplatSender)
{
sBugSplatSender->createReport((EXCEPTION_POINTERS*)pExcepInfo);
+ return true;
}
#endif // LL_BUGSPLAT
+ return false;
}
void LLAppViewerWin32::initLoggingAndGetLastDuration()
diff --git a/indra/newview/llappviewerwin32.h b/indra/newview/llappviewerwin32.h
index 2242c95b06..250e72edf3 100644
--- a/indra/newview/llappviewerwin32.h
+++ b/indra/newview/llappviewerwin32.h
@@ -43,7 +43,7 @@ public:
bool init() override; // Override to do application initialization
bool cleanup() override;
- void reportCrashToBugsplat(void* pExcepInfo) override;
+ bool reportCrashToBugsplat(void* pExcepInfo) override;
protected:
void initLoggingAndGetLastDuration() override; // Override to clean stack_trace info.