Currently if the drawable gets updated the old one will stay as the window current drawable and on the DC (where it got when SetPixelFormat was called on it). Currently if drawable gets updated in get_updated_drawable() it is essentially leaked (will be destroyed only once the context and the window are destroyed), and also it may be occasionally updated and flicker onscreen / offscreen fighting with actual new surface (from update_client_surfaces()). I suppose what the first patch changes is essentially a typo and the intention was to update window to the new drawable. Then, I don't see why would we want to leave the old surface on the current context once we replaced it (fixed in patch 2). -- https://gitlab.winehq.org/wine/wine/-/merge_requests/10190#note_130552