Index: handler/mac/crash_report_exception_handler.cc |
diff --git a/handler/mac/crash_report_exception_handler.cc b/handler/mac/crash_report_exception_handler.cc |
index 404bfcac0ae20abde6158eb4005353422ac570d9..43531d4cabcc2166499a34867dfbbea34a417875 100644 |
--- a/handler/mac/crash_report_exception_handler.cc |
+++ b/handler/mac/crash_report_exception_handler.cc |
@@ -36,37 +36,6 @@ |
namespace crashpad { |
-namespace { |
- |
-// Calls CrashReportDatabase::ErrorWritingCrashReport() upon destruction unless |
-// disarmed by calling Disarm(). Armed upon construction. |
-class CallErrorWritingCrashReport { |
- public: |
- CallErrorWritingCrashReport(CrashReportDatabase* database, |
- CrashReportDatabase::NewReport* new_report) |
- : database_(database), |
- new_report_(new_report) { |
- } |
- |
- ~CallErrorWritingCrashReport() { |
- if (new_report_) { |
- database_->ErrorWritingCrashReport(new_report_); |
- } |
- } |
- |
- void Disarm() { |
- new_report_ = nullptr; |
- } |
- |
- private: |
- CrashReportDatabase* database_; // weak |
- CrashReportDatabase::NewReport* new_report_; // weak |
- |
- DISALLOW_COPY_AND_ASSIGN(CallErrorWritingCrashReport); |
-}; |
- |
-} // namespace |
- |
CrashReportExceptionHandler::CrashReportExceptionHandler( |
CrashReportDatabase* database, |
CrashReportUploadThread* upload_thread, |
@@ -171,8 +140,8 @@ kern_return_t CrashReportExceptionHandler::CatchMachException( |
process_snapshot.SetReportID(new_report->uuid); |
- CallErrorWritingCrashReport call_error_writing_crash_report(database_, |
- new_report); |
+ CrashReportDatabase::CallErrorWritingCrashReport |
+ call_error_writing_crash_report(database_, new_report); |
WeakFileHandleFileWriter file_writer(new_report->handle); |