mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 906147 - Make sure we lock component alpha textures in the correct order to prevent deadlocks. r=nrc
This commit is contained in:
parent
ad0de92b78
commit
971cc56ca4
@ -472,14 +472,20 @@ ContentClientDoubleBuffered::SyncFrontBufferToBackBuffer()
|
||||
AutoDeprecatedTextureClient autoTextureFront;
|
||||
AutoDeprecatedTextureClient autoTextureFrontOnWhite;
|
||||
if (SupportsAzureContent()) {
|
||||
RotatedBuffer frontBuffer(autoTextureFront.GetDrawTarget(mFrontClient),
|
||||
autoTextureFrontOnWhite.GetDrawTarget(mFrontClientOnWhite),
|
||||
// We need to ensure that we lock these two buffers in the same
|
||||
// order as the compositor to prevent deadlocks.
|
||||
DrawTarget* dt = autoTextureFront.GetDrawTarget(mFrontClient);
|
||||
DrawTarget* dtOnWhite = autoTextureFrontOnWhite.GetDrawTarget(mFrontClientOnWhite);
|
||||
RotatedBuffer frontBuffer(dt,
|
||||
dtOnWhite,
|
||||
mFrontBufferRect,
|
||||
mFrontBufferRotation);
|
||||
UpdateDestinationFrom(frontBuffer, updateRegion);
|
||||
} else {
|
||||
RotatedBuffer frontBuffer(autoTextureFront.GetSurface(mFrontClient),
|
||||
autoTextureFrontOnWhite.GetSurface(mFrontClientOnWhite),
|
||||
gfxASurface* surf = autoTextureFront.GetSurface(mFrontClient);
|
||||
gfxASurface* surfOnWhite = autoTextureFrontOnWhite.GetSurface(mFrontClientOnWhite);
|
||||
RotatedBuffer frontBuffer(surf,
|
||||
surfOnWhite,
|
||||
mFrontBufferRect,
|
||||
mFrontBufferRotation);
|
||||
UpdateDestinationFrom(frontBuffer, updateRegion);
|
||||
|
Loading…
Reference in New Issue
Block a user