Skip to content
Commit bd8c296a authored by Vlad Zahorodnii's avatar Vlad Zahorodnii Committed by Nate Graham
Browse files

Fix crash in WindowThumbnail::updatePaintNode()

Recently, the WindowThumbnail was changed so it properly discards the
texture provider in the releaseResources() function.

But it appears like there's a case where the releaseResources() function
can be called in the windowToTexture() function, which will result in
use after free bugs.

Based on af5a855d, it looks like the
WindowThumbnail item didn't use QQuickItem::releaseResources() to
properly release its graphics resources. It was checking whether the
texture node still has a texture. If there's no texture, it means that
the texture got discarded and it needs to be re-created; otherwise it
is okay to re-use the old texture.

With QQuickItem::releaseResources(), we don't need that workaround
anymore since QtQuick will call the releaseResources() function whenever
it wants the WindowThumbnail to discard graphics resources.

BUG: 444015
parent a61587a0
Loading
Loading
Loading
Pipeline #89817 passed with stage
in 1 minute and 37 seconds
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment