| OLD | NEW |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 // | 4 // |
| 5 // Following an unclean shutdown, a stability report can be collected and | 5 // Following an unclean shutdown, a stability report can be collected and |
| 6 // submitted for upload to a reporter. | 6 // submitted for upload to a reporter. |
| 7 | 7 |
| 8 #ifndef COMPONENTS_BROWSER_WATCHER_POSTMORTEM_REPORT_COLLECTOR_H_ | 8 #ifndef COMPONENTS_BROWSER_WATCHER_POSTMORTEM_REPORT_COLLECTOR_H_ |
| 9 #define COMPONENTS_BROWSER_WATCHER_POSTMORTEM_REPORT_COLLECTOR_H_ | 9 #define COMPONENTS_BROWSER_WATCHER_POSTMORTEM_REPORT_COLLECTOR_H_ |
| 10 | 10 |
| (...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 94 crashpad::CrashReportDatabase* report_database); | 94 crashpad::CrashReportDatabase* report_database); |
| 95 | 95 |
| 96 // Virtual for unittesting. | 96 // Virtual for unittesting. |
| 97 // TODO(manzagop): move this for reuse in live scenario. | 97 // TODO(manzagop): move this for reuse in live scenario. |
| 98 virtual CollectionStatus Collect(const base::FilePath& debug_state_file, | 98 virtual CollectionStatus Collect(const base::FilePath& debug_state_file, |
| 99 std::unique_ptr<StabilityReport>* report); | 99 std::unique_ptr<StabilityReport>* report); |
| 100 void CollectThread( | 100 void CollectThread( |
| 101 const base::debug::ThreadActivityAnalyzer::Snapshot& snapshot, | 101 const base::debug::ThreadActivityAnalyzer::Snapshot& snapshot, |
| 102 ThreadState* thread_state); | 102 ThreadState* thread_state); |
| 103 | 103 |
| 104 virtual bool WriteReportToMinidump(const StabilityReport& report, | 104 virtual bool WriteReportToMinidump(StabilityReport* report, |
| 105 const crashpad::UUID& client_id, | 105 const crashpad::UUID& client_id, |
| 106 const crashpad::UUID& report_id, | 106 const crashpad::UUID& report_id, |
| 107 base::PlatformFile minidump_file); | 107 base::PlatformFile minidump_file); |
| 108 | 108 |
| 109 std::string product_name_; | 109 std::string product_name_; |
| 110 std::string version_number_; | 110 std::string version_number_; |
| 111 std::string channel_name_; | 111 std::string channel_name_; |
| 112 | 112 |
| 113 DISALLOW_COPY_AND_ASSIGN(PostmortemReportCollector); | 113 DISALLOW_COPY_AND_ASSIGN(PostmortemReportCollector); |
| 114 }; | 114 }; |
| 115 | 115 |
| 116 } // namespace browser_watcher | 116 } // namespace browser_watcher |
| 117 | 117 |
| 118 #endif // COMPONENTS_BROWSER_WATCHER_POSTMORTEM_REPORT_COLLECTOR_H_ | 118 #endif // COMPONENTS_BROWSER_WATCHER_POSTMORTEM_REPORT_COLLECTOR_H_ |
| OLD | NEW |