OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 #ifndef COMPONENTS_CRASH_CONTENT_APP_CRASHPAD_H_ | 5 #ifndef COMPONENTS_CRASH_CONTENT_APP_CRASHPAD_H_ |
6 #define COMPONENTS_CRASH_CONTENT_APP_CRASHPAD_H_ | 6 #define COMPONENTS_CRASH_CONTENT_APP_CRASHPAD_H_ |
7 | 7 |
8 #include <time.h> | 8 #include <time.h> |
9 | 9 |
10 #include <string> | 10 #include <string> |
11 #include <vector> | 11 #include <vector> |
12 | 12 |
13 #include "base/files/file_path.h" | 13 #include "base/files/file_path.h" |
14 | 14 |
| 15 #if defined(KASKO) |
| 16 #include "syzygy/kasko/api/crash_key.h" |
| 17 #endif // KASKO |
| 18 |
15 namespace crash_reporter { | 19 namespace crash_reporter { |
16 | 20 |
17 // Initializes Crashpad in a way that is appropriate for initial_client and | 21 // Initializes Crashpad in a way that is appropriate for initial_client and |
18 // process_type. | 22 // process_type. |
19 // | 23 // |
20 // If initial_client is true, this starts crashpad_handler and sets it as the | 24 // If initial_client is true, this starts crashpad_handler and sets it as the |
21 // exception handler. Child processes will inherit this exception handler, and | 25 // exception handler. Child processes will inherit this exception handler, and |
22 // should specify false for this parameter. Although they inherit the exception | 26 // should specify false for this parameter. Although they inherit the exception |
23 // handler, child processes still need to call this function to perform | 27 // handler, child processes still need to call this function to perform |
24 // additional initialization. | 28 // additional initialization. |
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
63 // The list will be sorted in descending order by report creation time (newest | 67 // The list will be sorted in descending order by report creation time (newest |
64 // reports first). | 68 // reports first). |
65 // | 69 // |
66 // TODO(mark): The about:crashes UI expects to show only uploaded reports. If it | 70 // TODO(mark): The about:crashes UI expects to show only uploaded reports. If it |
67 // is ever enhanced to work well with un-uploaded reports, those should be | 71 // is ever enhanced to work well with un-uploaded reports, those should be |
68 // returned as well. Un-uploaded reports may have a pending upload, may have | 72 // returned as well. Un-uploaded reports may have a pending upload, may have |
69 // experienced upload failure, or may have been collected while uploads were | 73 // experienced upload failure, or may have been collected while uploads were |
70 // disabled. | 74 // disabled. |
71 void GetUploadedReports(std::vector<UploadedReport>* uploaded_reports); | 75 void GetUploadedReports(std::vector<UploadedReport>* uploaded_reports); |
72 | 76 |
| 77 #if defined(KASKO) |
| 78 // Returns a copy of the current crash keys for Kasko. |
| 79 void GetCrashKeysForKasko(std::vector<kasko::api::CrashKey>* crash_keys); |
| 80 #endif // KASKO |
| 81 |
73 namespace internal { | 82 namespace internal { |
74 | 83 |
75 // The platform-specific portion of InitializeCrashpad(). | 84 // The platform-specific portion of InitializeCrashpad(). |
76 // Returns the database path, if initializing in the browser process. | 85 // Returns the database path, if initializing in the browser process. |
77 base::FilePath PlatformCrashpadInitialization(bool initial_client, | 86 base::FilePath PlatformCrashpadInitialization(bool initial_client, |
78 bool browser_process); | 87 bool browser_process); |
79 | 88 |
80 } // namespace internal | 89 } // namespace internal |
81 | 90 |
82 } // namespace crash_reporter | 91 } // namespace crash_reporter |
83 | 92 |
84 #endif // COMPONENTS_CRASH_CONTENT_APP_CRASHPAD_H_ | 93 #endif // COMPONENTS_CRASH_CONTENT_APP_CRASHPAD_H_ |
OLD | NEW |