Menu code accessed the screen buffer without a lock

This commit is contained in:
Magnus Norddahl 2017-02-13 15:42:35 +01:00
parent 69787fac72
commit 93f43e8751

View file

@ -198,6 +198,8 @@ void DCanvas::DrawTextureParms(FTexture *img, DrawParms &parms)
viewport->RenderTarget = screen; viewport->RenderTarget = screen;
viewport->RenderTarget->Lock(true);
if (APART(parms.colorOverlay) != 0) if (APART(parms.colorOverlay) != 0)
{ {
// The software renderer cannot invert the source without inverting the overlay // The software renderer cannot invert the source without inverting the overlay
@ -324,6 +326,8 @@ void DCanvas::DrawTextureParms(FTexture *img, DrawParms &parms)
{ {
NetUpdate(); NetUpdate();
} }
viewport->RenderTarget->Unlock();
#endif #endif
} }