Commit bc9407a4 authored by Piotr Pawłow's avatar Piotr Pawłow Committed by Alexandre Julliard

wined3d: Set container of swapchain surfaces to WINED3D_CONTAINER_NONE in…

wined3d: Set container of swapchain surfaces to WINED3D_CONTAINER_NONE in swapchain_init() error path.
parent 6ed2208e
......@@ -1072,7 +1072,10 @@ err:
for (i = 0; i < swapchain->presentParms.BackBufferCount; ++i)
{
if (swapchain->back_buffers[i])
{
surface_set_container(swapchain->back_buffers[i], WINED3D_CONTAINER_NONE, NULL);
wined3d_surface_decref(swapchain->back_buffers[i]);
}
}
HeapFree(GetProcessHeap(), 0, swapchain->back_buffers);
}
......@@ -1089,7 +1092,10 @@ err:
}
if (swapchain->front_buffer)
{
surface_set_container(swapchain->front_buffer, WINED3D_CONTAINER_NONE, NULL);
wined3d_surface_decref(swapchain->front_buffer);
}
return hr;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment