Remove contexts from WKCACFContextFlusher before destroying them
[WebKit-https.git] / Source / WebCore / platform / graphics / win / WKCACFLayerRenderer.cpp
index 4c5e61d1e0757966460e787b84e98eb00dd54faf..4d77fbdeaacfee4e3f755c0b9e665f044ea934f3 100644 (file)
@@ -225,6 +225,7 @@ WKCACFLayerRenderer::WKCACFLayerRenderer(WKCACFLayerRendererClient* client)
 WKCACFLayerRenderer::~WKCACFLayerRenderer()
 {
     destroyRenderer();
+    WKCACFContextFlusher::shared().removeContext(m_context);
     wkCACFContextDestroy(m_context);
 }