From b60ca9929377a9b45776f40e7467e1ed9846d04b Mon Sep 17 00:00:00 2001 From: "apatrick@chromium.org" Date: Mon, 20 Sep 2010 18:57:07 +0000 Subject: Fixed crash when ANGLE returns a NULL device. ANGLE shouldn't be returning a NULL device at this point. I'll get to that next. This will fix crashes for people using old DX8 cards. TEST=try BUG=none Review URL: http://codereview.chromium.org/3410018 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@59951 0039d316-1c4b-4281-b951-d872f2087c98 --- chrome/gpu/gpu_info_collector_win.cc | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'chrome/gpu') diff --git a/chrome/gpu/gpu_info_collector_win.cc b/chrome/gpu/gpu_info_collector_win.cc index d741fe4..1e3124b 100644 --- a/chrome/gpu/gpu_info_collector_win.cc +++ b/chrome/gpu/gpu_info_collector_win.cc @@ -26,7 +26,13 @@ bool CollectGraphicsInfo(GPUInfo* gpu_info) { egl::Display* display = static_cast( gfx::BaseEGLContext::GetDisplay()); + if (!display) + return false; + IDirect3DDevice9* device = display->getDevice(); + if (!device) + return false; + IDirect3D9* d3d = NULL; if (FAILED(device->GetDirect3D(&d3d))) return false; -- cgit v1.1