aboutsummaryrefslogtreecommitdiffhomepage
path: root/win32/PlatWin.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'win32/PlatWin.cxx')
-rw-r--r--win32/PlatWin.cxx2
1 files changed, 2 insertions, 0 deletions
diff --git a/win32/PlatWin.cxx b/win32/PlatWin.cxx
index febc82171..3c5a5adf3 100644
--- a/win32/PlatWin.cxx
+++ b/win32/PlatWin.cxx
@@ -1098,7 +1098,9 @@ void SurfaceD2D::Clear() noexcept {
clipsActive--;
}
if (ownRenderTarget) {
+ pRenderTarget->EndDraw();
pRenderTarget->Release();
+ ownRenderTarget = false;
}
pRenderTarget = nullptr;
}