Signed-off-by: Henri Verbeet hverbeet@codeweavers.com --- dlls/ddraw/surface.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/dlls/ddraw/surface.c b/dlls/ddraw/surface.c index 739e68f..30276b4 100644 --- a/dlls/ddraw/surface.c +++ b/dlls/ddraw/surface.c @@ -2069,7 +2069,7 @@ static HRESULT ddraw_surface_delete_attached_surface(struct ddraw_surface *surfa * particular, modify the QueryInterface() pointer in the surface vtbl * but don't cleanup properly after the relevant dll is unloaded. */ if (attachment->surface_desc.ddsCaps.dwCaps & DDSCAPS_ZBUFFER - && wined3d_device_get_depth_stencil_view(surface->ddraw->wined3d_device) == surface->wined3d_rtv) + && wined3d_device_get_depth_stencil_view(surface->ddraw->wined3d_device) == attachment->wined3d_rtv) wined3d_device_set_depth_stencil_view(surface->ddraw->wined3d_device, NULL); wined3d_mutex_unlock();