Fixed NULL dereference in glClear.
Fixed NULL dereference in glClear.

6 crashes on Windows XP
1 crash on Windows 7

This was Canary 7.0.530.0 using ANGLE r429.

0x011f523b 	[libGLESv2.dll 	- context.cpp:2412] 	gl::Context::clear(unsigned int)
0x011e5f41 	[libGLESv2.dll 	- libglesv2.cpp:611] 	glClear
0x020c400d 	[chrome.dll 	- gl_context.cc:33] 	gfx::GLContext::InitializeCommon()
0x020bb757 	[chrome.dll 	- gl_context_egl.cc:138] 	gfx::NativeViewEGLContext::Initialize()
0x020b8946 	[chrome.dll 	- gl_context_win.cc:502] 	gfx::GLContext::CreateViewGLContext(HWND__ *,bool)
0x01c4f6f8 	[chrome.dll 	- gpu_processor_win.cc:35] 	gpu::GPUProcessor::Initialize(HWND__ *,gfx::Size const &,gpu::GPUProcessor *,unsigned int)
0x01d6e669 	[chrome.dll 	- gpu_command_buffer_stub.cc:88] 	GpuCommandBufferStub::OnInitialize(int,void * *)

It's crashing upon creation of the GL context, possibly the first context. Device lost would possibly explain the XP crashes. The Windows 7 box might have run out of video memory.

I also checked another couple of NULL dereference crashes.


Review URL: http://codereview.appspot.com/2197046

git-svn-id: a070b70d2b8c44c266a3870c0cddd9a0ee470458@444 736b8ea6-26fd-11df-bfd4-992fa37f6226

ehsan/angle,ppy/angle,KTXSoftware/angleproject,crezefire/angle,themusicgod1/angleproject,csa7mdm/angle,xuxiandi/angleproject,cantren/angleproject,mlfarrell/angle,mrobinson/rust-angle,RepublicMaster/angleproject,vvuk/angle-old,vvuk/angle,mybios/angle,cantren/angleproject,csa7mdm/angle,themusicgod1/angleproject,cantren/angleproject,shairai/angleproject,android-ia/platform_external_chromium_org_third_party_angle_dx11,ecoal95/angle,ehsan/angle,vvuk/angle,MIPS/external-chromium_org-third_party-angle_dx11,MSOpenTech/angle,KTXSoftware/angleproject,mrobinson/rust-angle,android-ia/platform_external_chromium_org_third_party_angle,KalebDark/angleproject,themusicgod1/angleproject,ehsan/angle,MSOpenTech/angle,cvsuser-chromium/chromium-third-party_angle_dx11,MSOpenTech/angle,jgcaaprom/android_external_chromium_org_third_party_angle,KalebDark/angleproject,vvuk/angle-old,mikolalysenko/angle,ghostoy/angle,MIPS/external-chromium_org-third_party-angle,shairai/angleproject,android-ia/platform_external_chromium_org_third_party_angle_dx11,MIPS/external-chromium_org-third_party-angle_dx11,xuxiandi/angleproject,ecoal95/angle,larsbergstrom/angle,nandhanurrevanth/angle,larsbergstrom/angle,MIPS/external-chromium_org-third_party-angle_dx11,crezefire/angle,geekboxzone/lollipop_external_chromium_org_third_party_angle,mikolalysenko/angle,pombreda/angleproject,jgcaaprom/android_external_chromium_org_third_party_angle,xin3liang/platform_external_chromium_org_third_party_angle,MSOpenTech/angle-win8.0,ghostoy/angle,mybios/angle,csa7mdm/angle,nandhanurrevanth/angle,larsbergstrom/angle,xin3liang/platform_external_chromium_org_third_party_angle,mybios/angle,ppy/angle,ghostoy/angle,stammen/angleproject,crezefire/angle,ecoal95/angle,xin3liang/platform_external_chromium_org_third_party_angle_dx11,nandhanurrevanth/angle,cvsuser-chromium/chromium-third-party_angle_dx11,cvsuser-chromium/chromium-third-party_angle_dx11,ghostoy/angle,android-ia/platform_external_chromium_org_third_party_angle,ecoal95/angle,crezefire/angle,mybios/angle,mlfarrell/angle,stammen/angleproject,KalebDark/angleproject,KTXSoftware/angleproject,bsergean/angle,mlfarrell/angle,KalebDark/angleproject,shairai/angleproject,RepublicMaster/angleproject,geekboxzone/lollipop_external_chromium_org_third_party_angle,ecoal95/angle,vvuk/angle-old,mlfarrell/angle,mrobinson/rust-angle,csa7mdm/angle,jgcaaprom/android_external_chromium_org_third_party_angle,domokit/waterfall,vvuk/angle-old,domokit/waterfall,bsergean/angle,xin3liang/platform_external_chromium_org_third_party_angle_dx11,ppy/angle,xin3liang/platform_external_chromium_org_third_party_angle,bsergean/angle,stammen/angleproject,pombreda/angleproject,shairai/angleproject,android-ia/platform_external_chromium_org_third_party_angle,MIPS/external-chromium_org-third_party-angle,xuxiandi/angleproject,xin3liang/platform_external_chromium_org_third_party_angle_dx11,MIPS/external-chromium_org-third_party-angle_dx11,MIPS/external-chromium_org-third_party-angle,jgcaaprom/android_external_chromium_org_third_party_angle,xin3liang/platform_external_chromium_org_third_party_angle,vvuk/angle,nandhanurrevanth/angle,MSOpenTech/angle-win8.0,pombreda/angleproject,bsergean/angle,android-ia/platform_external_chromium_org_third_party_angle_dx11,mikolalysenko/angle,vvuk/angle,geekboxzone/lollipop_external_chromium_org_third_party_angle,larsbergstrom/angle,pombreda/angleproject,themusicgod1/angleproject,android-ia/platform_external_chromium_org_third_party_angle_dx11,cantren/angleproject,mrobinson/rust-angle,RepublicMaster/angleproject,mrobinson/rust-angle,geekboxzone/lollipop_external_chromium_org_third_party_angle,ehsan/angle,stammen/angleproject,cvsuser-chromium/chromium-third-party_angle_dx11,KTXSoftware/angleproject,ppy/angle,MSOpenTech/angle-win8.0,MSOpenTech/angle,android-ia/platform_external_chromium_org_third_party_angle,xuxiandi/angleproject,xin3liang/platform_external_chromium_org_third_party_angle_dx11,mikolalysenko/angle,MIPS/external-chromium_org-third_party-angle,MSOpenTech/angle-win8.0,RepublicMaster/angleproject,KTXSoftware/angleproject