diff options
author | thakis@chromium.org <thakis@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-09-15 20:07:19 +0000 |
---|---|---|
committer | thakis@chromium.org <thakis@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2010-09-15 20:07:19 +0000 |
commit | 43ed628c3e1fb8085c0cb377c19db5b73bf11214 (patch) | |
tree | 48e241b416782c63b6ac489f53929c2651cc1e67 /chrome/gpu | |
parent | d7a3eb035972863c1b011fe5aa47cc4353733910 (diff) | |
download | chromium_src-43ed628c3e1fb8085c0cb377c19db5b73bf11214.zip chromium_src-43ed628c3e1fb8085c0cb377c19db5b73bf11214.tar.gz chromium_src-43ed628c3e1fb8085c0cb377c19db5b73bf11214.tar.bz2 |
Add about:gpucrash
BUG=None
TEST=open a tab that uses the compositor. Open a second tab, go to about:gpucrash. Verify in the task manager that the gpu process is now gone.
Review URL: http://codereview.chromium.org/3424007
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@59540 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/gpu')
-rw-r--r-- | chrome/gpu/gpu_thread.cc | 8 | ||||
-rw-r--r-- | chrome/gpu/gpu_thread.h | 1 |
2 files changed, 9 insertions, 0 deletions
diff --git a/chrome/gpu/gpu_thread.cc b/chrome/gpu/gpu_thread.cc index f1e5148..97cb5d1 100644 --- a/chrome/gpu/gpu_thread.cc +++ b/chrome/gpu/gpu_thread.cc @@ -89,6 +89,8 @@ void GpuThread::OnControlMessageReceived(const IPC::Message& msg) { OnNewRenderWidgetHostView) IPC_MESSAGE_HANDLER(GpuMsg_CollectGraphicsInfo, OnCollectGraphicsInfo) + IPC_MESSAGE_HANDLER(GpuMsg_Crash, + OnCrash) IPC_END_MESSAGE_MAP_EX() } @@ -160,3 +162,9 @@ void GpuThread::OnCollectGraphicsInfo() { Send(new GpuHostMsg_GraphicsInfoCollected(gpu_info)); } + +void GpuThread::OnCrash() { + // Good bye, cruel world. + volatile int* it_s_the_end_of_the_world_as_we_know_it = NULL; + *it_s_the_end_of_the_world_as_we_know_it = 0xdead; +} diff --git a/chrome/gpu/gpu_thread.h b/chrome/gpu/gpu_thread.h index fb23d7f..519b092 100644 --- a/chrome/gpu/gpu_thread.h +++ b/chrome/gpu/gpu_thread.h @@ -42,6 +42,7 @@ class GpuThread : public ChildThread { void OnEstablishChannel(int renderer_id); void OnSynchronize(); void OnCollectGraphicsInfo(); + void OnCrash(); void OnNewRenderWidgetHostView(GpuNativeWindowHandle parent_window, int32 routing_id); |