mirror of
https://gitlab.winehq.org/wine/vkd3d.git
synced 2024-11-21 16:46:41 -08:00
vkd3d: Use vkd3d_atomic_increment_u32() in vkd3d_instance_incref().
This commit is contained in:
parent
edc406d297
commit
042e269791
Notes:
Alexandre Julliard
2024-01-29 22:53:07 +01:00
Approved-by: Giovanni Mascellani (@giomasce) Approved-by: Alexandre Julliard (@julliard) Merge-Request: https://gitlab.winehq.org/wine/vkd3d/-/merge_requests/609
@ -750,7 +750,7 @@ static void vkd3d_destroy_instance(struct vkd3d_instance *instance)
|
||||
|
||||
ULONG vkd3d_instance_incref(struct vkd3d_instance *instance)
|
||||
{
|
||||
ULONG refcount = InterlockedIncrement(&instance->refcount);
|
||||
unsigned int refcount = vkd3d_atomic_increment_u32(&instance->refcount);
|
||||
|
||||
TRACE("%p increasing refcount to %u.\n", instance, refcount);
|
||||
|
||||
@ -759,7 +759,7 @@ ULONG vkd3d_instance_incref(struct vkd3d_instance *instance)
|
||||
|
||||
ULONG vkd3d_instance_decref(struct vkd3d_instance *instance)
|
||||
{
|
||||
ULONG refcount = InterlockedDecrement(&instance->refcount);
|
||||
unsigned int refcount = InterlockedDecrement((LONG *)&instance->refcount);
|
||||
|
||||
TRACE("%p decreasing refcount to %u.\n", instance, refcount);
|
||||
|
||||
|
@ -192,7 +192,7 @@ struct vkd3d_instance
|
||||
|
||||
uint64_t host_ticks_per_second;
|
||||
|
||||
LONG refcount;
|
||||
unsigned int refcount;
|
||||
};
|
||||
|
||||
#ifdef _WIN32
|
||||
|
Loading…
Reference in New Issue
Block a user