vkd3d: Use vkd3d_atomic_increment_u32() in d3d12_fence_incref().

This commit is contained in:
Henri Verbeet 2024-01-11 20:26:16 +01:00 committed by Alexandre Julliard
parent 1b4f1ac8a0
commit c8122ff47e
Notes: Alexandre Julliard 2024-01-25 23:12:08 +01:00
Approved-by: Alexandre Julliard (@julliard)
Merge-Request: https://gitlab.winehq.org/wine/vkd3d/-/merge_requests/605
2 changed files with 3 additions and 3 deletions

View File

@ -935,7 +935,7 @@ static ULONG STDMETHODCALLTYPE d3d12_fence_AddRef(ID3D12Fence1 *iface)
static void d3d12_fence_incref(struct d3d12_fence *fence)
{
InterlockedIncrement(&fence->internal_refcount);
vkd3d_atomic_increment_u32(&fence->internal_refcount);
}
static ULONG STDMETHODCALLTYPE d3d12_fence_Release(ID3D12Fence1 *iface)
@ -953,7 +953,7 @@ static ULONG STDMETHODCALLTYPE d3d12_fence_Release(ID3D12Fence1 *iface)
static void d3d12_fence_decref(struct d3d12_fence *fence)
{
ULONG internal_refcount = InterlockedDecrement(&fence->internal_refcount);
ULONG internal_refcount = InterlockedDecrement((LONG *)&fence->internal_refcount);
if (!internal_refcount)
{

View File

@ -621,7 +621,7 @@ struct vkd3d_signaled_semaphore
struct d3d12_fence
{
ID3D12Fence1 ID3D12Fence1_iface;
LONG internal_refcount;
unsigned int internal_refcount;
unsigned int refcount;
D3D12_FENCE_FLAGS flags;