Commit 98cb3a5e authored by Lei Zhang's avatar Lei Zhang Committed by Commit Bot

Trigger crash tests with IMMEDIATE_CRASH().

Use a well defined way to do this.

Change-Id: Ifb70fdc002251d00b8db73e8f8a6130c7a126357
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2227113Reviewed-by: default avatarTom Sepez <tsepez@chromium.org>
Commit-Queue: Lei Zhang <thestig@chromium.org>
Cr-Commit-Position: refs/heads/master@{#774340}
parent 837537c8
...@@ -314,8 +314,7 @@ base::RunLoop* g_run_loop = nullptr; ...@@ -314,8 +314,7 @@ base::RunLoop* g_run_loop = nullptr;
void HandleTestParameters(const base::CommandLine& command_line) { void HandleTestParameters(const base::CommandLine& command_line) {
// This parameter causes a null pointer crash (crash reporter trigger). // This parameter causes a null pointer crash (crash reporter trigger).
if (command_line.HasSwitch(switches::kBrowserCrashTest)) { if (command_line.HasSwitch(switches::kBrowserCrashTest)) {
int* bad_pointer = nullptr; IMMEDIATE_CRASH();
*bad_pointer = 0;
} }
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment