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

Unified Diff: components/crash/browser/crash_dump_manager_android.cc

Issue 889083002: Initialize Android CrashDumpManager earlier (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 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/chrome_browser_main_android.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/crash/browser/crash_dump_manager_android.cc
diff --git a/components/crash/browser/crash_dump_manager_android.cc b/components/crash/browser/crash_dump_manager_android.cc
index 8ef0b7c58051ca91bf05b08a1d3f17512ee9dcd7..ee3afdd90af81cb05272dbe9476aea83f69e6b7d 100644
--- a/components/crash/browser/crash_dump_manager_android.cc
+++ b/components/crash/browser/crash_dump_manager_android.cc
@@ -29,13 +29,14 @@ CrashDumpManager* CrashDumpManager::instance_ = NULL;
// static
CrashDumpManager* CrashDumpManager::GetInstance() {
+ CHECK(instance_);
return instance_;
}
CrashDumpManager::CrashDumpManager(const base::FilePath& crash_dump_dir)
: crash_dump_dir_(crash_dump_dir) {
DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI));
- DCHECK(!instance_);
+ CHECK(!instance_);
Lei Zhang 2015/01/31 01:14:22 I haven't looked very hard, but are you worried th
cjhopman 2015/01/31 01:20:48 Thinking about it a bit, I think this one could pr
instance_ = this;
@@ -83,6 +84,7 @@ base::File CrashDumpManager::CreateMinidumpFile(int child_process_id) {
void CrashDumpManager::ProcessMinidump(const base::FilePath& minidump_path,
base::ProcessHandle pid) {
DCHECK(BrowserThread::CurrentlyOn(BrowserThread::FILE));
+ CHECK(instance_);
int64 file_size = 0;
int r = base::GetFileSize(minidump_path, &file_size);
DCHECK(r) << "Failed to retrieve size for minidump "
« no previous file with comments | « chrome/browser/chrome_browser_main_android.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698