Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1969)

Unified Diff: chrome/browser/android/crash_dump_manager.cc

Issue 11884042: Fix for a crasher when starting a renderer. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Synced Created 7 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/browser/android/crash_dump_manager.h ('k') | chrome/browser/chrome_browser_main_android.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/android/crash_dump_manager.cc
diff --git a/chrome/browser/android/crash_dump_manager.cc b/chrome/browser/android/crash_dump_manager.cc
index 66be4ce517f41c29c22355a17627ed15d2f8fd34..f079c51a2a0b00cf7688d2afd2dd0a6c4b18436a 100644
--- a/chrome/browser/android/crash_dump_manager.cc
+++ b/chrome/browser/android/crash_dump_manager.cc
@@ -25,8 +25,20 @@
using content::BrowserThread;
+// static
+CrashDumpManager* CrashDumpManager::instance_ = NULL;
+
+// static
+CrashDumpManager* CrashDumpManager::GetInstance() {
+ return instance_;
+}
+
CrashDumpManager::CrashDumpManager() {
DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI));
+ DCHECK(!instance_);
+
+ instance_ = this;
+
notification_registrar_.Add(this,
content::NOTIFICATION_RENDERER_PROCESS_TERMINATED,
content::NotificationService::AllSources());
@@ -42,6 +54,7 @@ CrashDumpManager::CrashDumpManager() {
}
CrashDumpManager::~CrashDumpManager() {
+ instance_ = NULL;
}
int CrashDumpManager::CreateMinidumpFile(int child_process_id) {
« no previous file with comments | « chrome/browser/android/crash_dump_manager.h ('k') | chrome/browser/chrome_browser_main_android.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698