mirror of
https://gitlab.winehq.org/wine/vkd3d.git
synced 2024-11-21 16:46:41 -08:00
vkd3d: Initialize all fields before calling d3d12_command_allocator_allocate_command_buffer().
Signed-off-by: Józef Kucia <jkucia@codeweavers.com> Signed-off-by: Henri Verbeet <hverbeet@codeweavers.com> Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
parent
8b846b07e7
commit
b500207b79
@ -4001,12 +4001,6 @@ static HRESULT d3d12_command_list_init(struct d3d12_command_list *list, struct d
|
||||
list->allocator = allocator;
|
||||
list->pipeline_state = initial_pipeline_state;
|
||||
|
||||
if (FAILED(hr = d3d12_command_allocator_allocate_command_buffer(allocator, list)))
|
||||
{
|
||||
ID3D12Device_Release(&device->ID3D12Device_iface);
|
||||
return hr;
|
||||
}
|
||||
|
||||
memset(list->strides, 0, sizeof(list->strides));
|
||||
list->ia_desc.sType = VK_STRUCTURE_TYPE_PIPELINE_INPUT_ASSEMBLY_STATE_CREATE_INFO;
|
||||
list->ia_desc.pNext = NULL;
|
||||
@ -4025,6 +4019,12 @@ static HRESULT d3d12_command_list_init(struct d3d12_command_list *list, struct d
|
||||
|
||||
list->state = NULL;
|
||||
|
||||
if (FAILED(hr = d3d12_command_allocator_allocate_command_buffer(allocator, list)))
|
||||
{
|
||||
ID3D12Device_Release(&device->ID3D12Device_iface);
|
||||
return hr;
|
||||
}
|
||||
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user