diff options
author | wolfbeast <mcwerewolf@gmail.com> | 2018-03-30 08:50:58 +0200 |
---|---|---|
committer | wolfbeast <mcwerewolf@gmail.com> | 2018-03-30 08:50:58 +0200 |
commit | 4e368f8199a61c6319621ad1b9d6c352f0319f41 (patch) | |
tree | 69c6e2296c4e183ecbe6cfd1e856619e3715ae01 /dom/ipc/CrashReporterParent.cpp | |
parent | 59bf4204a84f7638d3f89a29bc7c04e5dc401369 (diff) | |
download | UXP-4e368f8199a61c6319621ad1b9d6c352f0319f41.tar UXP-4e368f8199a61c6319621ad1b9d6c352f0319f41.tar.gz UXP-4e368f8199a61c6319621ad1b9d6c352f0319f41.tar.lz UXP-4e368f8199a61c6319621ad1b9d6c352f0319f41.tar.xz UXP-4e368f8199a61c6319621ad1b9d6c352f0319f41.zip |
Remove base conditional code for crash reporter and injector.
Diffstat (limited to 'dom/ipc/CrashReporterParent.cpp')
-rw-r--r-- | dom/ipc/CrashReporterParent.cpp | 83 |
1 files changed, 0 insertions, 83 deletions
diff --git a/dom/ipc/CrashReporterParent.cpp b/dom/ipc/CrashReporterParent.cpp index fc627387f..677b29670 100644 --- a/dom/ipc/CrashReporterParent.cpp +++ b/dom/ipc/CrashReporterParent.cpp @@ -13,13 +13,6 @@ #include "mozilla/Telemetry.h" -#ifdef MOZ_CRASHREPORTER -#include "nsExceptionHandler.h" -#include "nsICrashService.h" -#include "mozilla/SyncRunnable.h" -#include "nsThreadUtils.h" -#endif - namespace mozilla { namespace dom { @@ -29,9 +22,6 @@ void CrashReporterParent::AnnotateCrashReport(const nsCString& key, const nsCString& data) { -#ifdef MOZ_CRASHREPORTER - mNotes.Put(key, data); -#endif } void @@ -49,9 +39,6 @@ CrashReporterParent::RecvAppendAppNotes(const nsCString& data) CrashReporterParent::CrashReporterParent() : -#ifdef MOZ_CRASHREPORTER - mNotes(4), -#endif mStartTime(::time(nullptr)) , mInitialized(false) { @@ -72,75 +59,5 @@ CrashReporterParent::SetChildData(const NativeThreadId& tid, mProcessType = GeckoProcessType(processType); } -#ifdef MOZ_CRASHREPORTER -bool -CrashReporterParent::GenerateCrashReportForMinidump(nsIFile* minidump, - const AnnotationTable* processNotes) -{ - if (!CrashReporter::GetIDFromMinidump(minidump, mChildDumpID)) { - return false; - } - - bool result = GenerateChildData(processNotes); - FinalizeChildData(); - return result; -} - -bool -CrashReporterParent::GenerateChildData(const AnnotationTable* processNotes) -{ - MOZ_ASSERT(mInitialized); - - if (mChildDumpID.IsEmpty()) { - NS_WARNING("problem with GenerateChildData: no child dump id yet!"); - return false; - } - - nsAutoCString type; - switch (mProcessType) { - case GeckoProcessType_Content: - type = NS_LITERAL_CSTRING("content"); - break; - case GeckoProcessType_Plugin: - case GeckoProcessType_GMPlugin: - type = NS_LITERAL_CSTRING("plugin"); - break; - default: - NS_ERROR("unknown process type"); - break; - } - mNotes.Put(NS_LITERAL_CSTRING("ProcessType"), type); - - char startTime[32]; - SprintfLiteral(startTime, "%lld", static_cast<long long>(mStartTime)); - mNotes.Put(NS_LITERAL_CSTRING("StartupTime"), nsDependentCString(startTime)); - - if (!mAppNotes.IsEmpty()) { - mNotes.Put(NS_LITERAL_CSTRING("Notes"), mAppNotes); - } - - // Append these notes to the end of the extra file based on the current - // dump id we obtained from CreatePairedMinidumps. - bool ret = CrashReporter::AppendExtraData(mChildDumpID, mNotes); - if (ret && processNotes) { - ret = CrashReporter::AppendExtraData(mChildDumpID, *processNotes); - } - - if (!ret) { - NS_WARNING("problem appending child data to .extra"); - } - return ret; -} - -void -CrashReporterParent::FinalizeChildData() -{ - MOZ_ASSERT(mInitialized); - - CrashReporterHost::NotifyCrashService(mProcessType, mChildDumpID, &mNotes); - mNotes.Clear(); -} -#endif - } // namespace dom } // namespace mozilla |