Index: chrome/browser/tracing/chrome_tracing_delegate.cc |
diff --git a/chrome/browser/tracing/chrome_tracing_delegate.cc b/chrome/browser/tracing/chrome_tracing_delegate.cc |
index bd30679443e98af21fa6702541b3ca8159ac656f..238e21f005f3d01e744105e38e5d1185767a2b65 100644 |
--- a/chrome/browser/tracing/chrome_tracing_delegate.cc |
+++ b/chrome/browser/tracing/chrome_tracing_delegate.cc |
@@ -83,10 +83,17 @@ bool ProfileAllowsScenario(const content::BackgroundTracingConfig& config, |
return true; |
} |
+#if !defined(OS_ANDROID) |
// Safeguard, in case background tracing is responsible for a crash on |
// startup. |
if (profile->GetLastSessionExitType() == Profile::EXIT_CRASHED) |
return false; |
+#else |
+ // In case of Android the exit state is always set as EXIT_CRASHED. So, |
+ // preemptive mode cannot be used safely. |
+ if (config.tracing_mode() == content::BackgroundTracingConfig::PREEMPTIVE) |
+ return false; |
+#endif |
PrefService* local_state = g_browser_process->local_state(); |
DCHECK(local_state); |