From 098ba64c4c2e15defb469b791fb3e88f89ae8759 Mon Sep 17 00:00:00 2001 From: Axel Davy Date: Sat, 3 Dec 2016 18:58:00 +0100 Subject: [PATCH] st/nine: Detach buffers in swapchain dtor. BackBuffers can survive swapchain dtor if the user has a reference on them. The swapchain itself has no reference on the buffer. Signed-off-by: Axel Davy --- src/gallium/state_trackers/nine/swapchain9.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/gallium/state_trackers/nine/swapchain9.c b/src/gallium/state_trackers/nine/swapchain9.c index feaece2f77f..9815acf7a4a 100644 --- a/src/gallium/state_trackers/nine/swapchain9.c +++ b/src/gallium/state_trackers/nine/swapchain9.c @@ -508,7 +508,7 @@ NineSwapChain9_dtor( struct NineSwapChain9 *This ) for (i = 0; i < This->num_back_buffers; i++) { if (This->buffers[i]) - NineUnknown_Release(NineUnknown(This->buffers[i])); + NineUnknown_Detach(NineUnknown(This->buffers[i])); if (This->present_handles[i]) ID3DPresent_DestroyD3DWindowBuffer(This->present, This->present_handles[i]); if (This->present_buffers[i]) -- 2.30.2