Skip to content

Commit

Permalink
One more fix related to atomic api change
Browse files Browse the repository at this point in the history
  • Loading branch information
shirok committed Nov 7, 2024
1 parent abfbb19 commit 1ec2a26
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/system.c
Original file line number Diff line number Diff line change
Expand Up @@ -3089,8 +3089,8 @@ int Scm__WinFastLockLock(ScmInternalFastlock spin)
{
/* spin may be NULL when FASTLOCK_LOCK is called on already-closed port. */
if (spin != NULL) {
ScmAtomicVar idle = 0;
while (!Scm_AtomicCompareExchange(&spin->lock_state, idle, 1)) {
ScmAtomicWord idle = 0;
while (!Scm_AtomicCompareExchange(&spin->lock_state, &idle, 1)) {
/* idle might be changed */
idle = 0;
/* it might be slow */
Expand Down

0 comments on commit 1ec2a26

Please sign in to comment.