[Webkit-unassigned] [Bug 155431] Leak: Accelerated ImageBufferCairo doesn't destroy the used textures

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Mon Mar 14 06:46:53 PDT 2016


https://bugs.webkit.org/show_bug.cgi?id=155431

--- Comment #2 from Zan Dobersek <zan at falconsigh.net> ---
Comment on attachment 273958
  --> https://bugs.webkit.org/attachment.cgi?id=273958
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=273958&action=review

> Source/WebCore/platform/graphics/cairo/ImageBufferCairo.cpp:88
> +    if (!m_texture)
> +        return;

I assume m_texture has to be present for m_compositorTexture to be created, but it would be better not to count on that, and just either delete m_texture or m_compositorTexture if they are non-null.

> Source/WebCore/platform/graphics/cairo/ImageBufferCairo.cpp:90
> +    GLContext::sharingContext()->makeContextCurrent();

This destructor should store the previous context and restore it when done, as we usually do.

At some point, we should also use a separate offscreen context for the accelerated canvas, and not the sharing context.

> Source/WebCore/platform/graphics/cairo/ImageBufferDataCairo.h:58
> +    ~ImageBufferData();

This should be virtual.

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.webkit.org/pipermail/webkit-unassigned/attachments/20160314/04bc61f8/attachment.html>


More information about the webkit-unassigned mailing list