Bug 1319508 - Ensure that we don't leave dangling pointers to CompositorBridgeParent in LayerTreeState instances. r?dvander
MozReview-Commit-ID: 3dxZ35uIQu
--- a/gfx/layers/ipc/CompositorBridgeParent.h
+++ b/gfx/layers/ipc/CompositorBridgeParent.h
@@ -353,17 +353,17 @@ public:
CreateForContent(Endpoint<PCompositorBridgeParent>&& aEndpoint);
struct LayerTreeState {
LayerTreeState();
~LayerTreeState();
RefPtr<Layer> mRoot;
RefPtr<GeckoContentController> mController;
APZCTreeManagerParent* mApzcTreeManagerParent;
- CompositorBridgeParent* mParent;
+ RefPtr<CompositorBridgeParent> mParent;
LayerManagerComposite* mLayerManager;
// Pointer to the CrossProcessCompositorBridgeParent. Used by APZCs to share
// their FrameMetrics with the corresponding child process that holds
// the PCompositorBridgeChild
CrossProcessCompositorBridgeParent* mCrossProcessParent;
TargetConfig mTargetConfig;
APZTestData mApzTestData;
LayerTransactionParent* mLayerTree;