Bug 1268122 - Guard against layerview destruction between the compositor update task being posted and it running. r?snorp
MozReview-Commit-ID: HJIFbcduj6E
--- a/mobile/android/base/java/org/mozilla/gecko/gfx/GLController.java
+++ b/mobile/android/base/java/org/mozilla/gecko/gfx/GLController.java
@@ -137,16 +137,20 @@ public class GLController extends JNIObj
updateCompositor();
}
});
}
void updateCompositor() {
ThreadUtils.assertOnUiThread();
+ if (mView == null) {
+ return;
+ }
+
if (mCompositorCreated) {
// If the compositor has already been created, just resume it instead. We don't need
// to block here because if the surface is destroyed before the compositor grabs it,
// we can handle that gracefully (i.e. the compositor will remain paused).
resumeCompositor(mWidth, mHeight);
return;
}