diff options
-rw-r--r-- | content/browser/browser_main_loop.cc | 10 | ||||
-rw-r--r-- | ui/gl/gl_surface_android.cc | 3 |
2 files changed, 9 insertions, 4 deletions
diff --git a/content/browser/browser_main_loop.cc b/content/browser/browser_main_loop.cc index 05b679a..8bcc3d3 100644 --- a/content/browser/browser_main_loop.cc +++ b/content/browser/browser_main_loop.cc @@ -932,16 +932,20 @@ int BrowserMainLoop::BrowserThreadsStarted() { #if !defined(OS_IOS) HistogramSynchronizer::GetInstance(); + bool initialize_gpu_data_manager = true; #if defined(OS_ANDROID) // On Android, GLSurface::InitializeOneOff() must be called before initalizing // the GpuDataManagerImpl as it uses the GL bindings. crbug.com/326295 - if (!gfx::GLSurface::InitializeOneOff()) - LOG(FATAL) << "GLSurface::InitializeOneOff failed"; + if (!gfx::GLSurface::InitializeOneOff()) { + LOG(ERROR) << "GLSurface::InitializeOneOff failed"; + initialize_gpu_data_manager = false; + } #endif // Initialize the GpuDataManager before we set up the MessageLoops because // otherwise we'll trigger the assertion about doing IO on the UI thread. - GpuDataManagerImpl::GetInstance()->Initialize(); + if (initialize_gpu_data_manager) + GpuDataManagerImpl::GetInstance()->Initialize(); bool always_uses_gpu = true; bool established_gpu_channel = false; diff --git a/ui/gl/gl_surface_android.cc b/ui/gl/gl_surface_android.cc index 9452232..1304b38 100644 --- a/ui/gl/gl_surface_android.cc +++ b/ui/gl/gl_surface_android.cc @@ -32,7 +32,7 @@ bool GLSurface::InitializeOneOffInternal() { // static scoped_refptr<GLSurface> GLSurface::CreateViewGLSurface( gfx::AcceleratedWidget window) { - + CHECK_NE(kGLImplementationNone, GetGLImplementation()); if (GetGLImplementation() == kGLImplementationOSMesaGL) { scoped_refptr<GLSurface> surface(new GLSurfaceOSMesaHeadless()); if (!surface->Initialize()) @@ -55,6 +55,7 @@ scoped_refptr<GLSurface> GLSurface::CreateViewGLSurface( // static scoped_refptr<GLSurface> GLSurface::CreateOffscreenGLSurface( const gfx::Size& size) { + CHECK_NE(kGLImplementationNone, GetGLImplementation()); switch (GetGLImplementation()) { case kGLImplementationOSMesaGL: { scoped_refptr<GLSurface> surface(new GLSurfaceOSMesa(1, size)); |