Chromium Code Reviews| Index: android_webview/browser/aw_browser_main_parts.cc |
| diff --git a/android_webview/browser/aw_browser_main_parts.cc b/android_webview/browser/aw_browser_main_parts.cc |
| index d30b07d66f5c564768a98f0d52257e4abbd4c54a..99adf49ea58e6ff46fad6aa728adee1200b1102a 100644 |
| --- a/android_webview/browser/aw_browser_main_parts.cc |
| +++ b/android_webview/browser/aw_browser_main_parts.cc |
| @@ -5,6 +5,7 @@ |
| #include "android_webview/browser/aw_browser_main_parts.h" |
| #include "android_webview/browser/aw_browser_context.h" |
| +#include "android_webview/browser/aw_browser_terminator.h" |
| #include "android_webview/browser/aw_content_browser_client.h" |
| #include "android_webview/browser/aw_result_codes.h" |
| #include "android_webview/browser/deferred_gpu_command_service.h" |
| @@ -19,7 +20,7 @@ |
| #include "base/files/file_path.h" |
| #include "base/i18n/rtl.h" |
| #include "base/path_service.h" |
| -#include "components/crash/content/browser/crash_micro_dump_manager_android.h" |
| +#include "components/crash/content/browser/crash_dump_observer_android.h" |
| #include "content/public/browser/android/synchronous_compositor.h" |
| #include "content/public/browser/render_frame_host.h" |
| #include "content/public/browser/render_process_host.h" |
| @@ -81,6 +82,8 @@ AwBrowserMainParts::AwBrowserMainParts(AwContentBrowserClient* browser_client) |
| } |
| AwBrowserMainParts::~AwBrowserMainParts() { |
| + breakpad::CrashDumpObserver::GetInstance()->UnregisterClient( |
| + aw_browser_terminator_); |
| } |
| void AwBrowserMainParts::PreEarlyInitialization() { |
| @@ -115,10 +118,12 @@ int AwBrowserMainParts::PreCreateThreads() { |
| base::android::MemoryPressureListenerAndroid::RegisterSystemCallback( |
| base::android::AttachCurrentThread()); |
| DeferredGpuCommandService::SetInstance(); |
| + breakpad::CrashDumpObserver::Create(); |
| if (!base::CommandLine::ForCurrentProcess()->HasSwitch( |
| switches::kSingleProcess)) { |
| // Create the renderers crash manager on the UI thread. |
| - breakpad::CrashMicroDumpManager::GetInstance(); |
| + breakpad::CrashDumpObserver::GetInstance()->RegisterClient( |
| + aw_browser_terminator_ = new AwBrowserTerminator()); |
|
boliu
2016/10/13 21:07:18
that is some weird syntax..
write this on two lin
Tobias Sargeant
2016/12/08 16:41:41
Done.
|
| } |
| return content::RESULT_CODE_NORMAL_EXIT; |