From 9af54e742a70924fbb010cc46e7afd56038c024e Mon Sep 17 00:00:00 2001 From: Riccardo Bortolato Date: Thu, 5 Nov 2015 16:00:37 +0100 Subject: [PATCH] wined3d: Call wined3d_texture_{inc, dec}ref() instead of wined3d_surface_{inc, dec}ref() in device_switch_onscreen_ds(). Signed-off-by: Riccardo Bortolato Signed-off-by: Henri Verbeet Signed-off-by: Alexandre Julliard --- dlls/wined3d/device.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/dlls/wined3d/device.c b/dlls/wined3d/device.c index 4806e3dc6c9..caf1c32b60d 100644 --- a/dlls/wined3d/device.c +++ b/dlls/wined3d/device.c @@ -208,10 +208,10 @@ void device_switch_onscreen_ds(struct wined3d_device *device, surface_modify_ds_location(device->onscreen_depth_stencil, WINED3D_LOCATION_TEXTURE_RGB, device->onscreen_depth_stencil->ds_current_size.cx, device->onscreen_depth_stencil->ds_current_size.cy); - wined3d_surface_decref(device->onscreen_depth_stencil); + wined3d_texture_decref(device->onscreen_depth_stencil->container); } device->onscreen_depth_stencil = depth_stencil; - wined3d_surface_incref(device->onscreen_depth_stencil); + wined3d_texture_incref(device->onscreen_depth_stencil->container); } static BOOL is_full_clear(const struct wined3d_surface *target, const RECT *draw_rect, const RECT *clear_rect)