[PATCH v2 0/1] MR542: vkd3d: Unlock mutex in error case in d3d12_command_queue_CopyTileMappings
-- v2: vkd3d: Unlock mutex in error case in d3d12_command_queue_CopyTileMappings https://gitlab.winehq.org/wine/vkd3d/-/merge_requests/542
From: Fabian Maurer <dark.shadow4(a)web.de> --- libs/vkd3d/command.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/libs/vkd3d/command.c b/libs/vkd3d/command.c index 549f6a45f..013b5d075 100644 --- a/libs/vkd3d/command.c +++ b/libs/vkd3d/command.c @@ -6512,7 +6512,7 @@ static void STDMETHODCALLTYPE d3d12_command_queue_CopyTileMappings(ID3D12Command if (!(op = d3d12_command_queue_op_array_require_space(&command_queue->op_queue))) { ERR("Failed to add op.\n"); - return; + goto unlock_mutex; } op->opcode = VKD3D_CS_OP_COPY_MAPPINGS; op->u.copy_mappings.dst_resource = dst_resource_impl; @@ -6524,6 +6524,7 @@ static void STDMETHODCALLTYPE d3d12_command_queue_CopyTileMappings(ID3D12Command d3d12_command_queue_submit_locked(command_queue); +unlock_mutex: vkd3d_mutex_unlock(&command_queue->op_mutex); } -- GitLab https://gitlab.winehq.org/wine/vkd3d/-/merge_requests/542
On Mon Jan 8 17:58:19 2024 +0000, Henri Verbeet wrote:
Could we say "unlock" instead of "free" here? The latter suggests calling vkd3d_mutex_destroy() instead of vkd3d_mutex_unlock(). Sure, updated both the MR and the commit title.
-- https://gitlab.winehq.org/wine/vkd3d/-/merge_requests/542#note_56930
This merge request was approved by Henri Verbeet. -- https://gitlab.winehq.org/wine/vkd3d/-/merge_requests/542
participants (3)
-
Fabian Maurer -
Fabian Maurer (@DarkShadow44) -
Henri Verbeet (@hverbeet)