diff --git a/gfx/thebes/gfxPlatform.cpp b/gfx/thebes/gfxPlatform.cpp index 4b2fd1d9aa9f..f41b79921e41 100644 --- a/gfx/thebes/gfxPlatform.cpp +++ b/gfx/thebes/gfxPlatform.cpp @@ -474,6 +474,8 @@ gfxPlatform::Shutdown() gPlatform->mMemoryPressureObserver = nullptr; } + gPlatform->DestroySkiaGLGlue(); + #ifdef MOZ_WIDGET_ANDROID // Shut down the texture pool mozilla::gl::TexturePoolOGL::Shutdown(); @@ -881,6 +883,12 @@ gfxPlatform::GetSkiaGLGlue() return mSkiaGlue; } +void +gfxPlatform::DestroySkiaGLGlue() +{ + mSkiaGlue = nullptr; +} + void gfxPlatform::PurgeSkiaCache() { diff --git a/gfx/thebes/gfxPlatform.h b/gfx/thebes/gfxPlatform.h index 8922b36ff466..09b7fc895c10 100644 --- a/gfx/thebes/gfxPlatform.h +++ b/gfx/thebes/gfxPlatform.h @@ -589,6 +589,7 @@ public: bool UseDeprecatedTextures() const { return mLayersUseDeprecated; } mozilla::gl::SkiaGLGlue* GetSkiaGLGlue(); + void DestroySkiaGLGlue(); void PurgeSkiaCache(); protected: