diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-08 15:18:07 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-08 15:18:07 +0000 |
commit | 328078c4d259e52db1a4848c00ee0b420775c91c (patch) | |
tree | ca9b0e61a1c03f0246b0371423bbbe570193e2f1 /mozglue/misc/RuntimeExceptionModule.cpp | |
parent | Adding upstream version 115.8.0esr. (diff) | |
download | firefox-esr-328078c4d259e52db1a4848c00ee0b420775c91c.tar.xz firefox-esr-328078c4d259e52db1a4848c00ee0b420775c91c.zip |
Adding upstream version 115.9.0esr.upstream/115.9.0esr
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'mozglue/misc/RuntimeExceptionModule.cpp')
-rw-r--r-- | mozglue/misc/RuntimeExceptionModule.cpp | 18 |
1 files changed, 5 insertions, 13 deletions
diff --git a/mozglue/misc/RuntimeExceptionModule.cpp b/mozglue/misc/RuntimeExceptionModule.cpp index 6b7e55c5e9..9a76bb22df 100644 --- a/mozglue/misc/RuntimeExceptionModule.cpp +++ b/mozglue/misc/RuntimeExceptionModule.cpp @@ -21,7 +21,6 @@ # include <werapi.h> // For WerRegisterRuntimeExceptionModule() # include <stdlib.h> -# include "mozilla/mozalloc_oom.h" # include "mozilla/Unused.h" using mozilla::Unused; @@ -31,12 +30,6 @@ namespace CrashReporter { #ifdef XP_WIN -struct InProcessWindowsErrorReportingData { - uint32_t mProcessType; - size_t* mOOMAllocationSizePtr; -}; - -static InProcessWindowsErrorReportingData gInProcessWerData; const static size_t kModulePathLength = MAX_PATH + 1; static wchar_t sModulePath[kModulePathLength]; @@ -86,10 +79,9 @@ void RegisterRuntimeExceptionModule() { return; } - gInProcessWerData.mProcessType = mozilla::GetGeckoProcessType(); - gInProcessWerData.mOOMAllocationSizePtr = &gOOMAllocationSize; - if (FAILED(::WerRegisterRuntimeExceptionModule(sModulePath, - &gInProcessWerData))) { + if (FAILED(::WerRegisterRuntimeExceptionModule( + sModulePath, + reinterpret_cast<PVOID>(mozilla::GetGeckoProcessType())))) { // The registration failed null out sModulePath to record this. *sModulePath = L'\0'; return; @@ -101,8 +93,8 @@ void UnregisterRuntimeExceptionModule() { #ifdef XP_WIN // If sModulePath is set then we have registered the module. if (*sModulePath) { - Unused << ::WerUnregisterRuntimeExceptionModule(sModulePath, - &gInProcessWerData); + Unused << ::WerUnregisterRuntimeExceptionModule( + sModulePath, reinterpret_cast<PVOID>(mozilla::GetGeckoProcessType())); *sModulePath = L'\0'; } #endif // XP_WIN |