avoid second NPE in Android x86 crashtest (createFrame)
☠☠ backed out by 047daa761fe0 ☠ ☠
authorGeoff Brown <gbrown@mozilla.com>
Tue, 17 Feb 2015 09:36:01 -0700
changeset 326740 81a1a3b6862d71cbb841c6ec8ec97301ccb2cd0d
parent 326739 a8f3584e772709fd2f1b97d5f16c0972c349dfd3
child 326741 6bdbe725837d18ec860022888ad41b91bc72d0f0
push id10169
push userdminor@mozilla.com
push dateThu, 28 Jan 2016 13:10:48 +0000
milestone38.0a1
avoid second NPE in Android x86 crashtest (createFrame)
mobile/android/base/gfx/GeckoLayerClient.java
--- a/mobile/android/base/gfx/GeckoLayerClient.java
+++ b/mobile/android/base/gfx/GeckoLayerClient.java
@@ -724,16 +724,19 @@ class GeckoLayerClient implements LayerV
 
         return syncViewportInfo(x, y, width, height, resolution, layersUpdated);
     }
 
     @WrapElementForJNI(allowMultithread = true)
     public LayerRenderer.Frame createFrame() {
         // Create the shaders and textures if necessary.
         if (!mLayerRendererInitialized) {
+            if (mLayerRenderer == null) {
+                return null;
+            }
             mLayerRenderer.checkMonitoringEnabled();
             mLayerRenderer.createDefaultProgram();
             mLayerRendererInitialized = true;
         }
 
         try {
             return mLayerRenderer.createFrame(mFrameMetrics);
         } catch (Exception e) {