wined3d: Fix up the backbuffer count on failure in swapchain_init().

This commit is contained in:
Henri Verbeet 2014-01-08 10:56:15 +01:00 committed by Alexandre Julliard
parent 2401a82bdc
commit ddae20b689

View file

@ -952,6 +952,7 @@ static HRESULT swapchain_init(struct wined3d_swapchain *swapchain, struct wined3
parent, &surface_desc, &swapchain->back_buffers[i])))
{
WARN("Failed to create back buffer %u, hr %#x.\n", i, hr);
swapchain->desc.backbuffer_count = i;
goto err;
}
surface_set_swapchain(swapchain->back_buffers[i], swapchain);